Collection Contents Index -m database option Next PDF

SQL Anywhere® Server - Database Administration  > The Database Server  > The SQL Anywhere database server  > Database options

-n database option


Sets the name of the database. The -n database option must be specified after the database-file, and applies only to that database.

Syntax

{ dbsrv10 | dbeng10 } [ server-options ] database-file -n string ...

Applies to

All operating systems and servers.

Remarks

Both database servers and databases can be named. Since a database server can load several databases, the database name is used to distinguish the different databases.

By default, the database receives the name of the database file with the path and extension removed. For example, if the database is started on samples-dir\demo.db and no -n option is specified, the name of the database is demo.

Database names cannot:

Example

The following example starts the database server with a cache size of 3 MB, loads the database, and names the database test. Since no database server name has been specified, the server takes its name from the first database, so the server's name is also test.

dbsrv10 -c 3MB "c:\mydata.db" -n "test"
There are two -n options

The -n option is position dependent. If it appears before a database file name, it is a server option and names the server. If it appears after a database file name, it is a database option and names the database.

For example, the following command names the server SERV and the database DATA:

dbsrv10 -n SERV c:\mydata.db -n DATA

See -n server option.


Collection Contents Index -m database option Next PDF