Create remote procedures

Use one of the following procedures to issue a remote procedure call.

Remote procedures accept input parameters up to 254 bytes in length, and return up to 254 characters in output variables.

If a remote procedure can return a result set, even if it does not always return one, then the local procedure definition must contain a RESULT clause.

 To create a remote procedure (Sybase Central)
  1. Use the SQL Anywhere 12 plug-in to connect to the host database as a user with DBA authority.

  2. In the left pane, double-click Remote Servers.

  3. Select the remote server, and in the right pane click the Remote Procedures tab.

  4. From the File menu, choose New » Remote Procedure.

  5. Follow the instructions in the Create Remote Procedure Wizard.

 To create a remote procedure (SQL)
  1. Connect to the host database as a user with DBA authority.

  2. Execute a statement to define the procedure to SQL Anywhere. For example:

    CREATE PROCEDURE RemoteWho()
    AT 'bostonase.master.dbo.sp_who';

    The syntax is similar to a local procedure definition. The location string defines the location of the procedure.

For more information, see CREATE PROCEDURE statement.

 To issue a remote procedure call (SQL)
  1. Connect to the database as a user with DBA authority.

  2. Execute the procedure as follows:

    CALL RemoteWho();
 Example
 Data types for remote procedures