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

Home -> Community -> Usenet -> c.d.o.server -> Re: Help What is the SQLPLUS escape character ?

Re: Help What is the SQLPLUS escape character ?

From: John P. Early <jpe1_at_lehigh.edu>
Date: Mon, 26 Apr 1999 15:56:55 -0400
Message-ID: <3724C507.93DF242D@lehigh.edu>


Seigmund Akinwande Johnson wrote:

> I need to know what is escape character in oracle, I have a table which has
> data in it with apostrophes.
>
> 'ants
> so I can't do (select * from table where col like ' 'ant' ')
>
> SAJ
Use double single quotes (aka apostrophes). For example, SQL> insert into mytable values ('''ant'); 1 row created.

SQL> select * from mytable where mycol = '''ant'; mycol



'ant

John.

--
John Early jpe1_at_lehigh.edu x85066 Senior Programmer, Enterprise Systems Implementation Lehigh University, Bethlehem, Pennsylvania qotd: "The meek shall inherit the Earth when the rest of us take to the stars" Received on Mon Apr 26 1999 - 14:56:55 CDT

Original text of this message

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