MichaelF81
Programmer
In a table 'Qustn' field 'qustntext' some of the values have a quotation mark at the end. THe last character is "
How Do I remove only this.
produces
"Adults are just obsolete children and the hell with them." - Dr. Seuss
How Do I remove only this.
Code:
SELECT QustnText
FROM dbo.Qustn
WHERE LTrim(RIGHT(qustntext, Len(qustntext)) - CharIndex('"', qustntext))
produces
Server: Msg 170, Level 15, State 1, Line 3
Line 3: Incorrect syntax near ')'.
"Adults are just obsolete children and the hell with them." - Dr. Seuss