Datamaker: Getting log information from the Windows ODBC trace for ODBC data sources
search cancel

Datamaker: Getting log information from the Windows ODBC trace for ODBC data sources

book

Article ID: 43311

calendar_today

Updated On:

Products

CA Test Data Manager (Data Finder / Grid Tools)

Issue/Introduction

Introduction/Summary: 

While working on scenarios in Datamaker that deal with ODBC data sources (for example, MSSQL Server, DB2, etc.) - we sometimes need additional debug/logging information about the communication between Datamaker and the data source, in order to troubleshoot more effectively. All of this information is not captured in the Datamaker log file.

In such cases, using the trace facility from the ODBC Driver Manager could come in handy. The tracing allows the sequence of function calls made by an ODBC application (in this case, Datamaker) to be recorded into a log file. Tracing is performed by a trace DLL, which captures calls between the application and the Driver Manager, and between the Driver Manager and the driver.

This article describes the steps to start and stop ODBC tracing.

 

Environment:  

Datamaker 3.1.x, 3.2.x, 3.5.x

 

Instructions: 

 To start ODBC tracing:

1. Open the 32-bit ODBC Data Source Administrator tool. On 64-bit OS platforms, this will be located at "C:\Windows\SysWOW64\odbcad32.exe".

2. Make sure that the profile DSN you are connecting to from Datamaker, and trying to obtain logging for, shows up in the User or System DSN list.

3. Click the "Tracing" tab.

4. You can specify the name of the log file in the "Log File Path" text box along with the full path.

5. Click "Start Tracing Now" to enable tracing. Now, this button reads "Stop Tracing Now". (Refer to the attached screenshot)

6. Click OK.

 

Once tracing is enabled, rerun the scenario from Datamaker for which ODBC logging information is required.

 

To stop ODBC tracing (after the troubleshooting scenario is complete), follow the steps provided above, except this time you must click "Stop Tracing Now", which would then read "Start Tracing Now". It is important to turn tracing off when you are done with the troubleshooting. If you keep tracing set to on, it degrades your application performance.

 

NOTE:

1. If tracing does not appear to be working (that is, no trace file is generated or an empty file is created), you can turn it on by editing the Windows registry directly. 

CAUTION: Before making any changes to the registry, make sure to take a backup of its current state.

To make sure tracing is turned on, follow these steps:

a. Open the Windows registry editor (C:\Windows\regedit.exe)

b. Navigate to the following registry key:

HKEY_LOCAL_MACHINE\Software\ODBC\ODBC.ini\ODBC  (if Datamaker is running under the System Account)

HKEY_CURRENT_USER\Software\ODBC\ODBC.ini\ODBC   (if Datamaker is running under the Current User Account)

c. Set "Trace" to 1 (and also make sure TraceDll and TraceFile are set to appropriate values. TraceFile should point to the log file location).

   This action forces tracing to be on for all ODBC applications (Refer to the attached screenshot).

 

Additional Information:

1. If you face issues while performing any of these steps, please open a Support ticket at https://support.ca.com.

2. For more details on ODBC tracing, refer to https://support.microsoft.com/en-us/kb/274551.

 

Environment

Release:
Component: ITKOGT