Forum Discussion

Adagio's avatar
Adagio
Frequent Contributor
7 years ago

Connecting TestComplete and DB2

Hello,

 

I have to run some SQL queries while running automated tests, and I would like to have TestComplete run these SQL queries to fetch the data from DB2 and then do some verifications. In order to do this, I need to have a connection established between TestComplete and DB2. Is there a way to do this or any examples available for this? I'm using Javascript to write these tests.

 

Any help would be greatly appreciated!

 

Thank you

Abhi

7 Replies

    • Adagio's avatar
      Adagio
      Frequent Contributor

      Thank you, Robert!

       

      I tried something but getting an error - [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

       

      Not sure what else is wrong or missing in the code.

      Here's the snapshot of what how I'm trying to do: 

       

       

       

       

      Thank you

      Abhi

       

       

      • AlexKaras's avatar
        AlexKaras
        Champion Level 3

        Hi,

         

        >  [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

        My guess based on the message text:

        -- You are trying to establish connection using ODBC DSN;

        -- TestComplete is 32-bit application and can use 32-bit DSNs only. So, if you are using 64-bit OS, you *must* install 32-bit driver and set DSN using 32-bit ODBC Administration utility started from <Windows>\SysWOW64 folder (e.g. as "C:\Windows\SysWOW64\odbcad32.exe").

         

        Does this help ?