SQL Foundations  «Prev 

Creating Databases Differs Between Database Engines

The bad news is that, depending on the database engine you are using, you will find that the commands you issue to create a database will vary widely.
Be sure to check with your database administrator for proper permissions and language syntax for your engine.
The good news is that, by and large, you do not need to create too many databases in your quest for information. It is more likely that you will be using existing databases, or that you will create tables inside an existing database. Remember, a database holds many tables; you do not need to create a new database each time you need to create a new table.

DB2 Version 9.7 for Linux, UNIX, and Windows

CREATE DATABASE command

Initializes a new database with an optional user-defined collating sequence, creates the three initial table spaces, creates the system tables, and allocates the recovery log file. When you initialize a new database, the AUTOCONFIGURE command is issued by default.
Note: When the instance and database directories are created by the DB2 database manager, the permissions are accurate and should not be changed. When the CREATE DATABASE command is issued, the Configuration Advisor also runs automatically. This means that the database configuration parameters are automatically tuned for you according to your system resources. In addition, Automated Runstats is enabled. To disable the Configuration Advisor from running at database creation, refer to the
DB2_ENABLE_AUTOCONFIG_DEFAULT
registry variable.
To disable Automated Runstats, refer to the auto_runstats database configuration parameter.

Adaptive Self Tuning Memory is also enabled by default for single partition databases.
To disable Adaptive Self Tuning Memory by default, refer to the self_tuning_mem database configuration parameter. For multi-partition databases, Adaptive Self Tuning Memory is disabled by default. If no code set is specified on the CREATE DATABASE command, then the collations allowed are:
SYSTEM, IDENTITY_16BIT, UCA400_NO, UCA400_LSK, UCA400_LTH, 
language-aware-collation, and locale-aware-collation (SQLCODE -1083). 

The default code set for a database is UTF-8. If a particular code set and territory is needed for a database, the desired code set and territory should be specified in the CREATE DATABASE command.