The name of the new database. The databaseName argument is a file name and is restricted by the naming and size limitations of the operating system. Any valid character that can be used in a file name can be used for the database name. If a path name is not specified, the database is created in the current directory. By default, the file name extension for a database name in SQL Server Compact 3.5 is .sdf.

'<enterStrongDatabasePasswordHere>'

SQL Server Compact 3.5 returns an error if a user connects to a password-protected database without a password. The database password must be enclosed in single quotation marks.

ENCRYPTION

If the optional ENCRYPTION ON keyword is used, the database is encrypted by using 128-bit encryption. You must specify a password to use encryption.

collationName

Specifies the default collation for the database. The collationName argument can only be a Windows collation. If collationName is not specified, the database is assigned the default collation of the device. For a list of collation names, see COLLATE (SQL Server Compact).

comparisonStyle

Specifies the comparison style of characters. The collationName and comparisonStyle parameters must not be enclosed in single or double quotation marks. SQL Server Compact 3.5 supports only CI_AS (case insensitive and accent sensitive) through the CREATE DATABASE statement. .

A. Creating a password-protected database

When a user tries to connect to a password-protected database without supplying the correct password, SQL Server Compact 3.5 returns an error. For information about errors, see SQL Server Compact Errors.

B. Creating a database that has a collation specified

The following example specifies a specific collation for the database being created.

Note When you create a new database, make sure that the correct collation is specified. If a table name is long and has mixed characters such as English and Japanese, the table might not be recognized in the subsequent connections to the database.