The eXtremeSQL Statistic Table

The eXtremeSQL Statistic table is a system maintained table that contains storage information about the contents of database tables. It can be accessed through the SQL select statement. For example the following command displays the memory occupied by 3 rows in a simple table Account:

 
    XSQL>create table Account(userid int, name string, lastlog date);
    XSQL>insert into Account values(1, 'Luke Skywalker', '1/1/1976');
    XSQL>insert into Account values(2, 'Han Solo', '1/2/1976');
    XSQL>insert into Account values(3, 'Darth Vader', '1/3/1976');
    XSQL>select * from Account;
    userid  name    lastlog
    -----------------------------------------------------------------
    1       Luke Skywalker  01/01/1976 00:00:00
    2       Han Solo        01/02/1976 00:00:00
    3       Darth Vader     01/03/1976 00:00:00
 
    Selected records: 3
    XSQL>select * from Statistic;
    TableName       ObjectsNum      VersionsNum     CorePages       BlobPages       SeqPages        CoreSpace
    -----------------------------------------------------------------
    Account 3       3       3       0       0       768
 
    Selected records: 1
     

The table columns have the following meanings:

TableName
The name of the database table (class)
ObjectsNum
Total number of rows in the table (instances of the class)
VersionsNum
Number of rows in the table (instances of the class) including all versions used at the moment (for MVCC)
CorePages
Number of pages used for all data except blobs (BLOB)

BlobPages

The number of pages used for blobs (BLOB)

SeqPages
The number of pages used by sequences

CoreSpace

Total number of bytes, not counting blobs