Marking tables to prepare for replication testing

This section describes how to mark tables in the primary Adaptive Server database that you want to replicate to the Sybase IQ database.

In these examples, dbo is the table owner of testtab in the pdb1 database of the ASE_DS primary Adaptive Server. c1, c2, and c3 are columns in testtab with int, int, and char(10) datatypes, respectively.

  1. Before you mark the tables, insert data rows into testtab for testing replication:

    insert into testtab values(1,1,‘testrow 1’)
    insert into testtab values(2,2,‘testrow 2’)
    insert into testtab values(3,3,‘testrow 3’)
    go
    

    If the inserts are successful, you see:

    (1 row affected)
    (1 row affected)
    (1 row affected)
    
    
  2. Mark testtab for replication:

    • ASE 15.0.3 and later:

      sp_setrepdefmode testtab,'owner_on'
      go
      
    • Versions earlier than ASE 15.0.3:

      sp_setreptable testtab,'true', 'owner_on'
      go
      

    You see:

    The replication status for 'testtab' is set to true,
    owner_on.