Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> how to escape single quotes

how to escape single quotes

From: kev <kevin.porter_at_fast.no>
Date: Wed, 29 Sep 1999 12:06:13 +0100
Message-ID: <37F1F2A5.7F7531B3@fast.no>


Hi,

How do I guard against single quotes in text messing up my SQL statements. For example, I have some text like:

'this is some text. It's got an apostrophe in it'

ie there's inadvertantly 3 single quotes there, which ruin the SQL statement. I could URL-encode the text first and URL-decode it afterwards (using PHP), but is there a 'proper' way to encode it (in Oracle 8)?

tia,

Received on Wed Sep 29 1999 - 06:06:13 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US