DBQL information can be used to find and observe OTF queries. The following queries can be used to find DBQL information for OTF queries.
Feature Usage Logging Count
To find the number of OTF queries that have been run
SELECT CAST(FeatureName AS CHAR(50)) AS FEATURENAME, FEATUREUSECOUNT
FROM DBC.QryLogFeatureUseCountV
WHERE FeatureName='Open Table Format' OR
FeatureName LIKE '%OTF TD_%' ORDER BY 2 DESC,1 ASC;
QryLogV View
The DBC.QryLogV view contains DBQL information for a query. For OTF queries, the field OTFQuery will be equal to 'T'.
SELECT * FROM DBC.QryLogV WHERE OTFQUERY='T';
DBC.QryLogV_SZ View
The DBC.QryLogV_SZ view contains DBQL information for a query run on a DBS with Zones. For OTF queries, the field OTFQuery will be equal to 'T'.
SELECT * FROM DBC.QryLogV_SZ WHERE OTFQUERY='T';
TD_METRIC_SVC.DBQLogV View
The TD_METRIC_SVC.DBQLogV view contains DBQL information for a query. For OTF queries, the field OTFQuery will be equal to 'T'.
SELECT * FROM TD_METRIC_SVC.DBQLogV WHERE OTFQUERY='T';
TD_METRIC_SVC.DBQLog_OperationsV View
The TD_METRIC_SVC.DBQLog_OperationsV view contains DBQL information for a query. For OTF queries, the field OTFQuery will be equal to 'T'.
SELECT * FROM TD_METRIC_SVC.DBQLog_OperationsV WHERE OTFQUERY='T';
PDCRINFO.DBQLogTbl View
The view PDCRINFO.DBQLogTbl is the same as TD_METRIC_SVC.DBQLogV and contains DBQL information for a query. For OTF queries, the field OTFQuery will be equal to 'T'.
SELECT * FROM PDCRINFO.DBQLogTbl WHERE OTFQUERY='T';
PDCRINFO.DBQLogTbl_Hst View
The view PDCRINFO.DBQLogTbl_Hst is the same as TD_METRIC_SVC.DBQLogV and contains DBQL information for a query. For OTF queries, the field OTFQuery will be equal to 'T'.
SELECT * FROM PDCRINFO.DBQLogTbl_Hst WHERE OTFQUERY='T';