Can I get my JDataStore server to trace SQL Statements?

Abstract: Can I get my JDataStore server to trace SQL Statements?

Problem Description

Can I get my JDataStore Server to trace SQL statements?


Problem Resolution

Yes you can and a lot more besides. There is a DBADMIN system stored procedure that can trace a number of events triggered by the server. This is SET_DATABASE_STATUS_LOG_FILTER. This takes an integer as a parameter. The value that you pass is�calculated by adding together the values defined in com.borland.datastore.driver.cons.LogFilterCodes. For example:

call DB_ADMIN.SET_DATABASE_STATUS_LOG_FILTER(1270)

will cause the server to start recording any connects, prepare, execute, transactions, errors, lock errors, and system errors that occur. These are recorded in the <DBNAME>_STATUS_* file found in the same directory as the database file.