I am trying to remove "question marks" (?) from a string of data.
Example:
SELECT REPLACE(<column_name>, '?', '') FROM <table_name>
However it does not remove the question mark (?). I also tried using CHAR(63) in place of '?' and it still doesn't work. Is there something special about "?" that doesn't allow the REPLACE function to work with them?
There is some weirdness involved here. The string in question is:
SYNTHETIC?/ PETROLEUM 2-CYCLE OIL
right after the "C" in SYNTHETIC and before the / there appears to be a space, but if you copy this (hidden character) and then run
SELECT ASCI('?') it returns 63
Running the following
SELECT CHAR(63) returns a ?
When viewing this product on the website it shows up as SYNTHETIC?/ PETROLEUM 2-CYCLE OIL. Any ideas what's going on and how can I fix this (yes I can delete it but I'd like to be able to fix this during runtime in case it comes back).
I am running SQL 2005 SP3 Developer Ed. on Windows 2003 sp2
Example:
SELECT REPLACE(<column_name>, '?', '') FROM <table_name>
However it does not remove the question mark (?). I also tried using CHAR(63) in place of '?' and it still doesn't work. Is there something special about "?" that doesn't allow the REPLACE function to work with them?
There is some weirdness involved here. The string in question is:
SYNTHETIC?/ PETROLEUM 2-CYCLE OIL
right after the "C" in SYNTHETIC and before the / there appears to be a space, but if you copy this (hidden character) and then run
SELECT ASCI('?') it returns 63
Running the following
SELECT CHAR(63) returns a ?
When viewing this product on the website it shows up as SYNTHETIC?/ PETROLEUM 2-CYCLE OIL. Any ideas what's going on and how can I fix this (yes I can delete it but I'd like to be able to fix this during runtime in case it comes back).
I am running SQL 2005 SP3 Developer Ed. on Windows 2003 sp2