Reports statistics on system usage.
sp_reportstats [loginame]
is the login name of the user to show accounting totals for.
Displays a report of current accounting totals for all Adaptive Server users:
sp_reportstats
Name Since CPU Percent CPU I/O Percent I/O ------ ----------- ----- ------------ ----- ------------- julie jun 19 1993 10000 24.9962% 5000 24.325% jason jun 19 1993 10002 25.0013% 5321 25.8866% ken jun 19 1993 10001 24.9987% 5123 24.9234% kathy jun 19 1993 10003 25.0038% 5111 24.865% Total CPU Total I/O --------- --------- 40006 20555
Displays a report of current accounting totals for user “kathy”:
sp_reportstats kathy
Name Since CPU Percent CPU I/O Percent I/O ------ ----------- ----- ------------ ----- ------------- kathy Jul 24 1993 498 49.8998% 48392 9.1829% Total CPU Total I/O --------- ---------- 998 98392
sp_reportstats prints out the current accounting totals for all logins, as well as each login’s individual statistics and percentage of the overall statistics. sp_reportstats accepts one parameter, the login name of the account to report. With no parameters, sp_reportstats reports on all accounts.
The units reported for “CPU” are Adaptive Server clock ticks.
The “probe” user exists for the two-phase commit probe process, which uses a challenge-and-response mechanism to access Adaptive Server.
Only a System Administrator can execute sp_reportstats.
Values in event and extrainfo columns from the sysaudits table are:
Event |
Audit option |
Command or access audited |
Information in extrainfo |
---|---|---|---|
38 |
exec_procedure |
Execution of a procedure |
|
System procedures sp_clearstats, sp_configure