[EMAIL PROTECTED] wrote:

> If i want to check the used resources, the number of rows read ...
> How can i turn on this feature?
> Are the results saved in data dictionary tables?

Sorry for the late reply but somehow I missed your mail.

In general you could get an overview on used resources with a 
"select * from monitor".
This table summarized all actions on the database.
With the command "monitor init" you could reset the global counters.

If you need detailed information on some commands you could use 
the diagnose monitor feature.

You have to switch it on with one of these commands:
 
  diagnose monitor selectivity <uint>
  diagnose monitor reads <uint>
  diagnose time <uint>

Where the <uint> stands for a threshold in case of selectivity 
for the rate rows read/rows qualified in permil, in case of reads 
for pages read and in case of time for total execution time of 
the command in milliseconds.

If a command execution exceeds those threshold its used resources 
were inserted into the system table sysmonitor.
Additionally every command text is inserted into the table sysparseid.
With the following join you can see the executed command and their 
used resources:

select /*+ordered */ substr(sp.sql_statement, 1, 6000), sm.* 
from sysmonitor sm, sysparseid sp 
where sm.parseid = sp.parseid

The ordered hint is neccessary because of an optimizer problem with 
temporary tables (we are working on that).

Be aware that the content of both tables are lost after a database 
restart and that the sysparsid could grow endlessly so your database
could overflow.

With "diagnose monitor off" you could switch the diagnose monitoring 
off again. 

HTH.

Kind regards,
Holger
SAP Labs Berlin


_______________________________________________
sapdb.general mailing list
[EMAIL PROTECTED]
http://listserv.sap.com/mailman/listinfo/sapdb.general

Reply via email to