listener could not hand off client connection after JavaScript conversion
We use successive database queries to be able to manipulate our app since TestComplete is not able to recognize certain grid objects(completely separate issue)
After about 20 successful calls back and forth I receive this error :
Error OraOLEDB ORA-12518: TNS:listener could not hand off client connection
var connectionObject = ADO.CreateConnection();
connectionObject.connectionString = "Provider=Oracle Provider for OLE DB;" + "Password="+ProjectSuite.Variables.FCPASSWORD + ";Persist Security Info=True;" + "User ID="+ProjectSuite.Variables.FCUSERNAME + ";Data Source="+ProjectSuite.Variables.DATABASE;
connectionObject.Open(); //THIS IS WHERE THE ERROR IS GENERATED
var recordSet = Sys.OleObject("ADODB.Recordset");
recordSet.Open("select meter_class from fc_meter_class order by meter_class asc", connectionObject, 3); // 3 indicates static cursor
Delay(200, "Building list of Meter Classs in memory");
classArray = recordSet.GetString();
recordSet.Close();
I also call connectionObject.Close() at the end of this function.... The above code has been modified based on SmartBears user documentation for JavaScript, here is what works flawlessly with JScript:
var connectionObject = new ActiveXObject("ADODB.Connection");
var connectionString = "Provider=Oracle Provider for OLE DB;" + "Password="+ProjectSuite.Variables.FCPASSWORD + ";Persist Security Info=True;" + "User ID="+ProjectSuite.Variables.FCUSERNAME + ";Data Source="+ProjectSuite.Variables.DATABASE;
connectionObject.Open(connectionString);
var recordSet = new ActiveXObject("ADODB.Recordset");
recordSet.Open("select meter_class from fc_meter_class order by meter_class asc", connectionObject, 3); // 3 indicates static cursor
Delay(200, "Building list of Meter Classs in memory");
classArray = recordSet.GetString();
recordSet.Close();