|
Posted by Roy Harvey on 10/21/06 19:40
Make a list of all the "white space" characters.
Use REPLACE to change each of them to the dash character. You could
nest them, but it might be simpler to loop through them, changing one
white space character in each UPDATE.
Then reduce multiple dashes to one by using REPLACE(whatever, '--',
'-') until no more rows are updated.
Roy
On 21 Oct 2006 09:05:10 -0700, feucos@gmail.com wrote:
>Hi all,
>
>I am new to these so plz never mind if this is funny.
>
>here is my problem :
>
>Table : moody
>
>Column : Title
>
>New column : Nospace
>
>I have data in "Title" column of many rows which are normal sentence.
>
>My requirment is to remove the "white space", +, | , ., / , ! @, $, %
>etc special characters and fill it by ( hyphen) and put it in new
>"Nospace" Column
>
>Example :
>
>I have : Hurray ! I won the Game
>
>Needed : Hurray-I-won-the-Game
>
>Can any body helpme in getting an SQL Query for this if possible
>
>Thanks in Advance
Navigation:
[Reply to this message]
|