Getting General run Error while opening connection for teradata using UFT(error number :-2147467259)

Hi,

I am faacing the General error while opening the connection for teradata. Please find the below code.

Please help me to resolve this issue. Thanks in Advance.

 

first I have created ODBC connection for Teradata then write code for execute query for teradata

------UFT Code---

Set cnDatabase = CreateObject("ADODB.Connection")

cnDatabase.CommandTimeOut=600000

' Note: DSNTeradata is my ODBS DSN Name

cnDatabase.ConnectionString="Data Source=DSNTeradata;Database=myDB;Persist Security Info=True;User Id=Tester1;Password=tester123;Session Mode=ANSI;"

cnDatabase.Open

Set ObjRecSetData = cnDatabase.Execute("select * from logtable")

------Code end-------

When cnDatabase.Open command run then throwing "General run error" Error number is :-2147467259.

Please let me know what is wrong in my code. please help