Nonstop Database, HiRDB Version 9 UAP Development Guide

[Contents][Index][Back][Next]

18.17.2 Estimating the Statement object size

The following shows the formulas for estimating the Statement object size.

Formula (for 32-bit mode)

Statement object size =
38000 + (2000 + retrieval results storage area size) x number of Statement instances (bytes)
 

Formula (for 64-bit mode)

Statement object size =
38000 + (2100 + retrieval results storage area size) x number of Statement instances (bytes)
 
Retrieval results storage area size: The value is 0 for non-retrieval SQL statements.
For retrieval SQL statements, use the following formula to determine the value:

[Figure]

Definition length of data in the column to be retrieved: If the column to be retrieved is BLOB or BINARY and the locator facility is used, the value is 4. If the locator facility is not used, the value is one of the following:
  • If HiRDB_for_Java_MAXBINARYSIZE is omitted:
    8 + definition length
  • If HiRDB_for_Java_MAXBINARYSIZE is specified:
    MIN(8 + definition length, 8 + MAXBINARYSIZE value)