Preparing remote databases

When you prepare a SQL Anywhere database to be used as a remote database on a device, you usually define a subset of the enterprise database that is relevant to the needs of the mobile application. There are several options available for building a SQL Anywhere database from an enterprise database:

After you have built the SQL Anywhere database, you can copy it to the device using Microsoft ActiveSync. You also need to create a DSN file and copy it to the root directory on the device. For more information, see “About SQL Anywhere data sources”.

Sybase Central

Sybase Central is a utility that allows developers to build a SQL Anywhere database from another database management system. (Sybase Central can be installed from the SQL Anywhere installation program.) For example, these are the steps needed to start with an Oracle database and build a SQL Anywhere database and use it with PocketBuilder:

  1. Open Sybase Central.

  2. Connect to an Oracle database.

  3. Migrate required tables to SQL Anywhere.

  4. Use MobiLink scripting capabilities to generate initial scripts.

  5. Use the PocketBuilder Database painter to view the database schema.

  6. Develop an application using the SQL Anywhere database in PocketBuilder.

  7. Deploy the application to the Windows CE device or emulator.

PowerDesigner

PowerDesigner Physical Data Model allows you to reverse-engineer enterprise databases and create corresponding SQL Anywhere databases. It also gives you the ability to manipulate the database schema. PowerDesigner Physical Data Model is provided with the full version of SQL Anywhere Studio. It is not provided with PocketBuilder.

Tools that come with your enterprise database

You can use the tools that come with your enterprise database to view the database schema. You can then create the SQL Anywhere database in the tool of your choice, such as Sybase Central, PowerDesigner, or a command-line tool.

For information about preparing remote databases for use with MobiLink, see Chapter 17, “Using MobiLink Synchronization.”