Use the following procedure to clean up and remove the replication test environment that you created in the previous sections.
To clean up and remove the replication test environment
Log in to the Mirror Replication Agent administration port using isql (or another query processor).
Use the following command to quiesce the Mirror Replication Agent instance:
quiesce
Use the following command to remove the Mirror Replication Agent transaction log and unmark the test primary table (mrx_test) in the Microsoft SQL Server database:
ra_deinit, force
Log in to the standby Replication Server and execute the following scripts:
%SYBASE%\MA-15_1\scripts\sybase\rs_drop_test_db_sub.sql (to drop the test subscription)
Edit the rs_drop_test_db_sub.sql script file so that the values for PDS.PDB in the with primary at clause match the PDS.PDB values that you used to create the connection for the primary data server and primary database. These values are initially {pds}.{pdb}. Also, change the values for SDS.SDB on the with replicate at clause to match the SDS.SDB values that you used to create the connection to the standby data server and standby database. These values are initially set to {sds}.{sdb}.
%SYBASE%\MA-15_1\scripts\sybase\rs_drop_test_db_repdef.sql (to drop the test replication definition)
%SYBASE%\MA-15_1\scripts\sybase\ rs_drop_test_primary_connection.sql (to drop the test connection to the primary database)
Log in to the standby data server and execute the mssql_drop_test_replicate_table.sql script in the %SYBASE%\MA-15_1\scripts\sybase\ directory to drop the test replicate table.
Use your Microsoft SQL Server database access tool (such as Microsoft sqlcmd) to log in to the Microsoft SQL Server data server and execute the mssql_drop_test_primary_table.sql script in the %SYBASE%\MA-15_1\scripts\mssql\ directory to drop the test primary table.
The mssql_drop_test_primary_table.sql script
does not specify a database name. You must either edit the script
to include a use command or invoke sqlcmd with
the -d option.