Grayson Hampton
asked on
Remove character from character string
How do I create a Case Statetment that deletes all ConsultantIDs that have an R and/or S?
ConsultantID
1001004
1001004R
1001004S
200311
200311R
200311S
ConsultantID
1001004
1001004R
1001004S
200311
200311R
200311S
ASKER
arana...
I would like to use this process in a Select statement that removes the characters.
I would like to use this process in a Select statement that removes the characters.
so you dont want to delete ConsultantID but rather remove the S and R characters from the field?
ASKER
@arana...
Yes, that is correct. I just want to delete S and R characters from the string.
Yes, that is correct. I just want to delete S and R characters from the string.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
@arana...
No I do not have a specific reason to use Case.
No I do not have a specific reason to use Case.
then one of the above examples will work for you
ASKER
Thank you arana for being extremely helpful and responsive.
delete from table where (charindex('S',ConsultantI