Way to check column with ADODriver?
I have ADODriver executing a SQL query that returns a small 3x2 table, and the value that I am needing is in the second column. Now, it isn't it's own column in the database, but rather a count of all of the matching entries in the database. I know I can use ADODriver to look at different rows, but what about different columns? I tried .Value[row][column] and it instead gave me the second character in the string in the first cell in the row (whereas .Value[row] returns the full value). Can I get it to see the second column, or will I need to rewrite the query to just return one column? Thanks!
The parameter of "Value" indicates the column in the current row. The ADODriver returns a collection of rows you iterate through and then you specify which column you want to work with using Value(<column indicator>).
So, you'll iterate through the rows using a while loop and then, each time through the loop, you reference Value(1). That will return the value of the 2nd column (column index is based on zero).
See https://support.smartbear.com/testcomplete/docs/reference/program-objects/ddtdriver/value.html