ASA SQL User's Guide
Monitoring and Improving Performance
Profiling database procedures
You can use stored procedures to view procedure profiling information. The profiling information is the same whether you view it in Sybase Central or in Interactive SQL.
The sa_procedure_profile_summary stored procedure provides information about all of the procedures within the database. You can use this procedure to view the profiling data for stored procedures, functions, events, and triggers within the same result set. The following parameters restrict the rows the procedure returns.
p_object_name specify the name of an object to profile.
p_owner_name specify the owner whose objects you want to profile.
p_table_name specify which table you want to profile triggers for.
p_object_type specify the type of object to profile. You can choose from the following four options. Choosing one of these values restricts the result set to only objects of the specified type.
P stored procedure
F function
T trigger
E event
p_ordering specify the sort order of the result set.
Keep in mind that there may be more items listed than those called specifically by users because one procedure can call another procedure.
The following sections assume that you are already connected to your database as a user with DBA authority and that you have procedure profiling enabled.
To view summary profiling information for all procedures
Execute the sa_procedure_profile_summary stored procedure.
For example, enter:
CALL sa_procedure_profile_summary
From the SQL menu, choose Execute.
A result set with information about all of the procedures in your database appears on the Results tab in the Results pane.
For more information about the sa_procedure_profile_summary stored procedure, see sa_procedure_profile_summary system procedure.
Viewing profiling information for a specific procedure in Interactive SQL