Hi Jim,

Are you building the SQL statements dynamically with concatenation? If so, why?

Normally, in RPG, you'd use embedded SQL and build your statement as a static statement. In this case, having a single quote in your "select where like" wouldn't do any harm!

But (although you haven't said this) I'm assuming you're building the statement dynamically... because I can't come up with any other reason why you'd have a problem like that. If that's the case, you can simply use parameter markers to solve the "special characters" problem. But I don't know why you'd do that instead of a static statement.

Can you please clarify your situation?



On 8/17/2010 11:30 AM, franz400@xxxxxxxxxxxx wrote:
Let me back up a bit...
I certainly agree proper sql can handle all characters, and
we have some old code around that have had to fix for
example: sql "select where like" and the parm passed for the
search value had single quote in it.
I guess I was looking to see if others had certain characters
they normally strip out and it seems not..
We do have in imports a check to remove characters not on a normal
keyboard, but that is not consistent, therefore trying to build a
standard list.
Jim

there's nothing intrinsic to sql that prohibits certain characters.
therefore to help you, we'd need to know what characters your program(s)
cant handle...


This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2026 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.