Calling procedures

CALL statements invoke procedures. Procedures can be called by an application program, or by other procedures.

For more information, see “CALL statement” in Chapter 6, “SQL Statements,” of the Sybase IQ Reference Manual.

The following statement calls the new_dept procedure to insert an Eastern Sales department:

CALL new_dept( 210, 'Eastern Sales', 902 );

After this call, you may wish to check the department table to see that the new department has been added.

All users who have been granted EXECUTE permissions for the procedure can call the new_dept procedure, even if they have no permissions on the department table.

For more information about EXECUTE permissions, see “Permissions to execute procedures”.