-
Problem with single quote in SQL 2K
Hi all,
I have a problem. I can code to insert a string which has single quote from screen into database. However, when I search from Query in database to find this record, it cannot find the record that I inserted.
For example: select UserID, Title from WCS_USER
where Title = ' how're you? '
Pls guide me how to solve this problem as soon as possible. Thank all of you.
-
SQL> create table dbj
2 (text varchar2(50));
Table created.
SQL> insert into dbj values ('Isn'||chr(39)||'t this better?');
1 row created.
SQL> select * from dbj;
TEXT
--------------------------------------------------
Isn't this better?
SQL> select * from dbj
2 where text = 'Isn\'t this better?';
ERROR:
ORA-01756: quoted string not properly terminated
SQL> select * from dbj
2 where text = 'Isn''t this better?';
TEXT
------------------------------------------------
Isn't this better?
-
Thank you so much! I now find out the solution .
Thanks again
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|