how to handle %SQLCODE = 100 case in select statement
Hi all,
I am using ExecDirect() method to execute my SQL query which is something like "SELECT * from Account where AccountNumber = ? "
But when I am providing a accountnumber that don't exists it doesn't return anything as aspected. while I am trying to check resultset.%SQLCODE in this case it is giving me 0 not 100. What's wrong with my SQL query and Also I there any other Property through which I check for if my resultset is null or it has some values.
Product version: IRIS 2023.2
Discussion (2)0
Comments
Hi!
I don't know if I've understood, but if you want to check if there's any result, you could test with %Next()
Set theresResult = resultset.%Next()
Your question has already been answered here: Dynamic SQL and Setting SQLCODE