Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I need to pass to a sub a parameter string containing a ' character
I have a sub executing the SQLSelect instruction to which I need to pass the where condition: for example
CALL runSQL(' zipcode like '%555%' ')
Is it possible to mask the ' character ?
Thanks
Hi Luca,
Try this:
Let mySQLWhereClause = chr(39) & 'zipcode like ' & chr(39) & '%555%' & chr(39) & chr(39);
//= 'zipcode like '%555%''
call mySQL (mySQLWhereClause);
Unless your DBMS requires it, you probably wont need the first and last chr(39)s.
-QB
Try using chr(39) instead of a single quote.