Kirix Support Forums

test for records returned

Please post any help questions, requests or other feedback here.

test for records returned

Postby abenitez77 on Thu Feb 16, 2012 7:03 pm

I am querying a database and trying to return a value. when there is no match and In my code it tries to assign the value to a variable, in the alert...it says "undefined". How can i test for the results that it returned no records?

var result1 = db.execute("select SQLServerID from SQLServer WHERE SQLServer = '" + ServerName.getText() + "'");

sqlID = result1.SQLServerID;
alert(sqlID);
abenitez77
Registered User
 
Posts: 143
Joined: Fri Jan 21, 2011 12:42 pm

Re: test for records returned

Postby abenitez77 on Fri Feb 17, 2012 9:23 am

I figured it out..
abenitez77
Registered User
 
Posts: 143
Joined: Fri Jan 21, 2011 12:42 pm

Return to Strata Help & Feedback