You can assign a function-string class to a database connection in Sybase Central or with the create connection or alter connection commands, executed in the Replication Server that manages the database. When you add a database connection using the rs_init program, the class rs_sqlserver_function_class is assigned to the database by default.
You must suspend the connection to the database before you alter the function-string class that is assigned to the database. The set function string class clause of create connection and alter connection specifies the name of the function-string class to use with the database.
Before you can assign a function-string class to a database connection:
The function-string class you specify must already exist and be available to the Replication Server. See “Creating a function-string class” for more information.
All necessary function strings must be created in the class. See “Creating function strings” for details.
When you create a connection using a connection profile, the function string class is assigned by the connection profile.
See “Creating database connections” on page 187 and “Altering database connections” on page 190 in the Replication Server Administration Guide Volume 1 for more information about using the create connection and alter connection commands, and connection profiles. Also refer to reference pages for these commands in the Replication Server Reference Manual.
Refer to the Replication Server installation and configuration guides for your platform for more information about rs_init.
The following command creates a connection to the pubs2 database managed by the TOKYO_DS data server:
create connection to TOKYO_DS.pubs2 set error class tokyo_error_class set function string class tokyo_func_class set username pubs2_maint set password pubs2_maint_pw
This command assigns the tokyo_func_class function-string class to the database connection.
The following command alters an existing database connection to specify a different function-string class:
alter connection to TOKYO_DS.pubs2 set function string class tokyo_func_class2