Creating Replication Server Functions

A replication function is a Replication Server object that represents a data server operation such as insert, delete, select, or begin transaction. Replication Server distributes such operations to other Replication Servers as functions. Each function consists of a function name and a set of data parameters. To execute the function in a destination database, Replication Server uses function strings to convert a function to a command or set of commands for a type of database. To create a replication function in Workspace, make sure your Replication Server is running and that you have established a connection, and then use the following procedure.

  1. Open Enterprise Explorer, and connect to your Replication Server.

  2. Expand the view for your Replication Server connection profile, right-click a primary database for which to create the function, and choose New Artifact from the context menu.

  3. From the wizard selection screen, select Function, and click Next to start the wizard.

  4. Modify the following fields.

    General settings

    FieldExample

    Function

    Enter a name for the function.

    Replication Definition

    Specify a replication definition for this function by selecting one from the menu drop-down.

    The changes made in this wizard page appear in the Preview field. Click Next to continue.

  5. Provide information for the following fields in the Parameters grid.

    Parameter settings

    FieldExample

    Name

    Type a name for each parameter in this text field.

    Data Type

    Click in this field once to add the default datatype, which is binary. To change the datatype, double-click in this field, and select a datatype from the menu drop-down.

    Length

    Type a length in bytes for this parameter.

    Use Remove and Remove All to remove parameter entries from this grid. The changes made on this wizard page appear in the Preview field.

  6. Click Finish to create the function. If the function is successfully created, it appears in the Functions folder for the specified replication definition.

Editing a Replication Server Function

Dropping a Replication Server Function

Send your feedback on this help topic to Sybase Tech Pubs: pubs@sybase.com