Use the create function command to register a replicated stored procedure with Replication Server.
When a stored procedure is executed, Replication Server maps it to a replication definition. The replication definition contains a user-defined function name that matches the name of the stored procedure.
Replication Server delivers the function to the Replication Server that is primary for the replication definition. When the destination Replication Server that owns the replication definition receives the function, it maps the stored procedure parameters into the commands for the user-defined function.
create function replication_definition.function ([@parameter datatype [, @parameter datatype]...])
The replication_definition must be an existing replication definition.
Execute this command at the Replication Server where the replication definition was created.
Do not use the names of system functions which are reserved.
Include the parentheses surrounding the listed parameters, even when you are defining functions with no parameters.
If you are not using a function-string class for which default generated function strings are provided, after you have created a user-defined function, use the create function string command to add a function string.
create function Items_rd.Stock_receipt (@Location int, @Recpt_num int, @Item_no char(15), @Qty_recd int)
When a user executes the replicated stored procedure, Replication Server now delivers it.