如何在j脚本函数中执行查询返回的记录?我正在尝试如下,但没有得到我做错的地方。
function getExecutableSteps()
{
var pad ="C:\\Automation\\Workspace\\Input\\Automation.accdb";
var cn = new ActiveXObject("ADODB.Connection");
var strConn = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" + pad;
cn.Open(strConn);
var cm = new ActiveXObject("ADODB.Command");
cm.ActiveConnection = cn;
cm.CommandText = "SELECT * FROM TestSteps where TestStepNo='TSU1_TC1_TST1'";
var rs = cm.Execute();
var TotalnoofRecords = rs.row.count;
Log.Message(TotalnoofRecords)
}