Consultor Eletrônico



Kbase P128146: Differences between _tablestat statistics and _usertablestat statistics
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   09/07/2008
Status: Verified

SYMPTOM(s):

Differences between _tablestat statistics and _usertablestat statistics

Number of reads reported by _usertablestat lower than values in _tablestat

Number of writes reported by _usertablestat lower than values in _tablestat

Number of deletes reported by _usertablestat lower than values in _tablestat

Number of gets reported by _usertablestat lower than values in _tablestat

FACT(s) (Environment):

All Supported Operating Systems
OpenEdge 10.1B

CAUSE:

This is expected behavior.

The _tablestat VST contains access statistics about a given table or range of tables since the database was started.

The _usertablestat VST contains access statistics about a given table or range of tables by user, but only for connected users. So unlike _tablestat, as soon as the user is disconnected, their USER stats are clearout.

FIX:

Use _tablestat to read persistent statistics that have accumulated since the database was started.

Code example:

FIND FIRST _statbase.
DISPLAY _tablebase WITH SIDE-LABELS.
FOR EACH _tablestat NO-LOCK
WHERE _tablestat-create <>0
OR _tablestat-delete <>0
OR _tablestat-read <> 0
OR _tablestat-update<> 0:
FIND _file WHERE _file-number = _tablestat-id NO-LOCK.
DISPLAY
_tablestat-id FORMAT "->>>9" LABEL "Table#" SKIP
_file-name format "x(20)" SKIP
_tablestat-read
_tablestat-create
_tablestat-delete
_tablestat-update WITH SIDE-LABELS.
END.