Is there a way for Access 2000 to log the SQL statements that are executed?

  • Thread starter Thread starter Raymond Martin
  • Start date Start date
R

Raymond Martin

I am using VB.NET and ACCESS 2000. Sometimes I need to execute SQL
statements from VB ADO against the Access database. It would make my
debugging easier if I could see the actual SQL statement as executed against
Access. Is there a way to turn on statement logging in Access?
 
Access. Is there a way to turn on statement logging in Access?

No, however this sometimes helps instead:

add the following key to the registry:
\\HKEY_LOCAL_MACHINE\SOFTWARE\MICROSOFT\Jet\3.0\Engines\Debug

Under this key, add a string data type entry named JETSHOWPLAN in
all capital letters. To turn ShowPlan on, set the value of this new
entry to "ON". To turn the feature off, set the value to "OFF". When
the feature is on, a text file called SHOWPLAN.OUT is created (or
appended to if it already exists) in the current directory.

This worked with some versions of Jet 4:
I haven't tried this with the latest release of Jet 4.

If it works, you will see other traffic as well as your
SQL, and it will crash if your SQL is at all complex.

(david)
 
Back
Top