Using stored procedures in HotStandby configurations
In HotStandby (HSB) configurations, all SQL stored procedures are executed in the primary server unless they are specified as read-only procedures, by using a standard ‘SQL data access indication’ clause in the procedure declaration, see CREATE PROCEDURE.
To avoid unnecessary handovers of procedures and functions to the primary server, use one of the following data access indication values in the procedure definition if the procedure does not update data:
▪ NO SQL
▪ READS SQL DATA
▪ CONTAINS SQL
For example:
"CREATE PROCEDURE PHONEBOOK_SEARCH (IN FIRST_NAME VARCHAR, LAST_NAME VARCHAR) RETURNS (PHONE_NR NUMERIC, CITY VARCHAR) READS SQL DATA BEGIN -- procedure_body END";