The below code works perfectly in developer:
var ans4 = globals.gSpecialist + globals.gClient;
if (currentcontroller.find()) {
specialist_client = ans4;
currentcontroller.search();
}
var foundOut2 = currentcontroller.getSelectedIndex();
if (foundOut2 == 0) {
//show dialog
thePressedButton = plugins.dialogs.showInfoDialog("Could not find record for...", globals.gSpecialist + " - " + globals.gClient, "OK");
} else {
if (foundOut2 == 1) {
thePressedButton = plugins.dialogs.showInfoDialog("Found one record for...", globals.gSpecialist + " - " + globals.gClient, "OK");
} else {
if (founeOut2 > 1) {
thePressedButton = plugins.dialogs.showInfoDialog("Duplicate record found for...", globals.gSpecialist + " - " + globals.gClient, "OK");
}
}
}
however, in the application server/smart client the code shows one record found when the globals fields are empty...
I checked the database with show all on a different layout and I don't see a record with blank or null fields...
is my method wrong or do I have corrupted database somehow? I replaced the server databases with the developer ones with the same result?
Thanks for helping...