Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 » UltraLite - Database Management and Reference » Using UltraLite Databases » Working with UltraLite databases » Working with UltraLite publications


Publishing a subset of rows from an UltraLite table

A publication can only contain specific table rows. In Sybase Central or Interactive SQL, a WHERE clause limits the rows that are uploaded to those that have changed and satisfy a search condition in the WHERE clause.

To upload all changed rows, do not specify a WHERE clause.

Palm OS

You cannot use a CREATE PUBLICATION statement with a WHERE clause on this platform.

Sybase Central

In Sybase Central, you can perform this task while working with the connected database.

To publish only some rows in an UltraLite table (Sybase Central)
  1. Connect to the UltraLite database.

  2. Right-click the Publications folder, and choose New » Publication.

  3. In the What Do You Want To Name The New Publication field, type a name for the new publication.

  4. Click Next.

  5. In the Available Tables list, select a table and click Add.

  6. Click the WHERE Clauses tab, and select the table from the Articles list. Optionally, you can use the Insert window to assist you in formatting the search condition.

  7. Click Finish.

Interactive SQL

In Interactive SQL, you can perform this task with the CREATE PUBLICATION statement.

To create a publication in UltraLite using a WHERE clause (Interactive SQL)
  1. Connect to the UltraLite database.

  2. Execute a CREATE PUBLICATION statement that includes the tables you want to include in the publication and a WHERE condition.

    For example, the following example creates a single-article publication that includes all sales order information for sales rep number 856:

    CREATE PUBLICATION pub_orders_samuel_singer
     ( TABLE SalesOrders
         WHERE SalesRepresentative = 856 );
See also