Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » SQL Anywhere Server - Database Administration » The SQL Anywhere SNMP Extension Agent » Using the SQL Anywhere SNMP Extension Agent

Setting values using the SQL Anywhere SNMP Extension Agent Next Page

Executing stored procedures using the SQL Anywhere SNMP Extension Agent


The SQL Anywhere MIB includes an OID that allows you to execute a stored procedure using the SQL Anywhere SNMP Extension Agent. In order to execute the stored procedure, the user that the SQL Anywhere SNMP Extension Agent uses to connect must have one of the following:

Any result sets or return values generated by the procedure are ignored.

To execute a stored procedure using the SQL Anywhere SNMP Extension Agent, set the value of saAgent.saProc (OID 1.3.6.1.4.1.897.2.3.5.db, where db is the database number in the sasnmp.ini file) to a string that is the name of a stored procedure. Optionally, you can supply arguments to the procedure; if no arguments are supplied, parentheses are appended to the procedure name.

For example, setting the value of saAgent.saProc to the string "pchin.updatesales( 'param1', 2)" calls the updatesales stored procedure owned by user pchin.

The way you set the value of this OID to the procedure name depends on your SNMP management software. See The SQL Anywhere MIB.