I am trying to write a method the value of one field in one record of a table. It seemed getDataSetByQuery is the best way to do this, but its not working.
Here is my code:
var myField = arguments[0]
var myTable = arguments[1]
var myWhere = arguments[2]
var mySql = "Select " + myField + " From " + myTable
if (myWhere > "")
mySql = mySql + " Where " + myWhere
var dataset = databaseManager.getDataSetByQuery(currentcontroller.getServerName(),mySql,null,1);
application.output(mySql)
application.output("dataset[0] "+dataset[0]+" dataset[1] "+dataset[1]);
Am I doing something wrong and/or is there a better way to do this?