Contents Index Setting up an UltraLite remote database Users in the CustDB sample

MobiLink Synchronization User's Guide
  The CustDB Sample Application

Tables in the CustDB databases


The table definitions for the CustDB database are in platform-specific files in the Samples\MobiLink\CustDB subdirectory of your SQL Anywhere 9 installation.

Both the consolidated and the remote databases contain the following five tables, although their definitions are slightly different in each location.

ULCustomer 

The ULCustomer table contains a list of customers.

In the remote database, ULCustomer has the following columns:

In the consolidated database, ULCustomer has the following additional column:

ULProduct 

The ULProduct table contains a list of products.

In the both the remote and consolidated databases, ULProduct has the following columns:

ULOrder 

The ULOrder table contains a list of orders, including details of the customer who placed the order, the employee who took the order, and the product being ordered.

In the remote database, ULOrder has the following columns:

In the consolidated database, ULOrder has the following additional column:

ULOrderIDPool 

The ULOrderIDPool table is a primary key pool for ULOrder.

In the remote database, ULOrderIDPool has the following column:

In the consolidated database, ULOrderIDPool has the following additional columns:

ULCustomerIDPool 

The ULCustomerIDPool table is a primary key pool for ULCustomer.

In the remote database, ULCustomerIDPool has the following column:

In the consolidated database, ULCustomerIDPool has the following additional columns:

The following tables are contained in the consolidated database only:

ULIdentifyEmployee_nosync 

The ULIdentifyEmployee_nosync table exists only in the consolidated database. It has a single column as follows:

ULEmployee 

The ULEmployee table exists only in the consolidated database. It contains a list of sales employees.

ULEmployee has the following columns:

ULEmpCust 

The ULEmpCust table controls which customers' orders will be downloaded. If the employee needs a new customer's orders, inserting the employee ID and customer ID will force the orders for that customer to be downloaded.

ULOldOrder and ULNewOrder 

These tables exists only in the consolidated database. They are for conflict resolution and contain the same columns as ULOrder. In Adaptive Server Anywhere and Microsoft SQL Server these are temporary tables. In Adaptive Server Enterprise, these are normal tables and @@spid. DB2 and Oracle do not have temporary tables, so MobiLink needs to be able to identify which rows belong to the synchronizing user. Since these are base tables, if five users are synchronizing, they might each have a row in these tables at the same time.

For more information about @@spid, see Variables.


Contents Index Setting up an UltraLite remote database Users in the CustDB sample