DBAsupport.com Forums - Powered by vBulletin
Results 1 to 2 of 2

Thread: How to use ' in single quotes in a update statement

  1. #1
    Join Date
    May 2001
    Location
    Fairfax, virginia
    Posts
    23

    How to use ' in single quotes in a update statement

    Hello, everyone,

    I have a problem to update one record to put a ' into a single quotes in a update statement.

    For example, update emp set last_name='john's' where id_no=2305;

    I got the error message of "not properly terminated";

    Could someone tell me how to put the ' into the single quotes in a update statement?

    Thanks a lot in advance.

    Gary

  2. #2
    Join Date
    Jul 2002
    Location
    Lake Worth, FL
    Posts
    1,492

    Cool

    Try:

    update emp set last_name='john''s' where id_no=2305;

    (Two single quotes together).
    "The person who says it cannot be done should not interrupt the person doing it." --Chinese Proverb

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width