In PocketBuilder you typically work within an existing database, but you can create a new local SQL Anywhere (Adaptive Server Anywhere) or UltraLite database from within PocketBuilder. You can also delete existing SQL Anywhere databases.
You can create a SQL Anywhere database in the Database painter or the Database Profiles dialog box.
To create a local SQL Anywhere database:
From the Objects view in the Database painter or the Database Profiles dialog box, launch the Create ASA Database utility.
The Create Adaptive Server Anywhere Database dialog box displays. (Adaptive Server Anywhere is the name for previous versions of SQL Anywhere.)
Select the version of SQL Anywhere (ASA Version) that you want to use to create the database, and enter a user ID and password for the new database.
In the Database Name box, specify the file name and path of the database you are creating.
If you do not provide a file extension, the database file name is given the extension DB.
Define other properties of the database as needed.
If you are using a non-English database, you can specify a code page in the Collation Sequence box.
For complete information about filling in the dialog box, click the Help button in the dialog box.
Click OK.
When you click OK, PocketBuilder does the following:
Creates a database with the specified name in the specified directory or folder. If a database with the same name exists, you are asked whether you want to replace it.
Adds a data source to the ODBC.INI key in the registry. The data source has the same name as the database unless one with the same name already exists, in which case a suffix is appended.
Creates a database profile and adds it to the registry. The profile has the same name as the database unless one with the same name already exists, in which case a suffix is appended.
Connects to the new database.
You can delete a SQL Anywhere database in the Database painter or the Database Profiles dialog box.
To delete a local SQL Anywhere database:
From the Objects view in the Database painter or the Database Profiles dialog box, launch the Delete ASA Database utility.
The Delete Local Database dialog box displays.
Select the database you want to delete and select Open.
Click Yes to delete the database.
When you click Yes, PocketBuilder deletes the specified database.
You can create UltraLite databases on the desktop with UltraLite administration tools, or on a handheld device with UltraLite APIs. The easiest way to create UltraLite databases is with Sybase Central using the UltraLite Create Database wizard or the MobiLink Create Synchronization Model wizard. You can launch Sybase Central 5.0 from the Utilities folder of the Database painter.
Creating an UltraLite 9 database You can create a new UltraLite 9 database using the UltraLite Schema Painter and Create UltraLite Database utilities. You can also create an UltraLite schema and database from an existing SQL Anywhere database. For an example, see the chapter on MobiLink synchronization in the Resource Guide for PocketBuilder 2.0.
For more information about creating UltraLite databases, see the UltraLite Database Management Reference book in the online book collection for SQL Anywhere Studio. For UltraLite 9 databases, see the UltraLite Database User’s Guide in the SQL Anywhere Studio 9 collection.