Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2004
    Posts
    26

    Unanswered: how do u filter out " ' " (apostrophe)?

    i'm trying to remove all the ' from a dataset

    update A set room = replace (' ' ', '') where room like '% ' %'

    but you can't because ' is reserved in oracle to delimit strings and characters..

    how would i be able to do this???

  2. #2
    Join Date
    Jan 2004
    Posts
    492
    If you need to represent a single quote inside a string, put 2 single quotes:

    EX:
    Code:
    select replace('john''s', '''', '_') from 
    dual
    Results in:
    Code:
    john_s
    Enjoy!
    Last edited by ss659; 10-25-04 at 13:02.
    Oracle OCPI (Certified Practicing Idiot)

Posting Permissions

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