Try OpenEdge Now
skip to main content
Debugging and Troubleshooting
Troubleshooting Resources : Log Entry Types Detail : Query information logging : Query statistics : Database block access
Database block access
When evaluating query efficiency, it is useful to consider the number of times the server performs database block accesses on behalf of the client. A disparity in the number of accesses to records returned could indicate poor index selection. OpenEdge tracks database block access on OpenEdge RDBMSs (but not on dataservers) in the _userio-dbaccess field of the _userio Virtual System Table as follows:
*For pre-pass queries, the number of blocks accessed is the difference between the number of block accesses immediately before the query starts building the result-list, and the number immediately after the query finishes building the list.
*For non-pre-pass queries, and for the reading of ABL records in pre-pass queries, the number of blocks accessed is the accumulation of accesses before and after each record fetch executed by the query.
A large number of database block accesses do not necessarily indicate a poorly conceived query. The number stored in the _userio-dbaccess field is a combined figure that includes both RM (data) and index block accesses. Although a high count on index accesses might predictably indicate inefficiencies in index use, a high count on RM accesses might simply mean that records are scattered throughout the database rather than in contiguous blocks. Thus, you have to weigh this value with other statistical data to determine query efficiency.
Note: Although not recommended, it is possible for a query to access tables in more than one database. For any such queries, OpenEdge records block access statistics for each database accessed. OpenEdge does not, however, track block access statistics for databases in single-user mode.