query
am 17.05.2006 15:19:51 von dave
hello,
i have a VARCHAR field that contains numbers which have spaces. example 4444
5555 6666
can anyone tell me a way to update the field to take out all the unwanted
spaces in one query.
until now i have been editing each record one by one
thanks
Re: query
am 17.05.2006 17:24:30 von Bill Karwin
Dave @ home wrote:
> can anyone tell me a way to update the field to take out all the unwanted
> spaces in one query.
UPDATE mytable SET mycolumn = REPLACE(mycolumn, ' ', '');
See http://dev.mysql.com/doc/refman/5.0/en/string-functions.html
Regards,
Bill K.
Re: query
am 17.05.2006 21:29:51 von dave
thanks bill
"Bill Karwin" wrote in message
news:e4ff7d02ivs@enews4.newsguy.com...
> Dave @ home wrote:
>> can anyone tell me a way to update the field to take out all the unwanted
>> spaces in one query.
>
> UPDATE mytable SET mycolumn = REPLACE(mycolumn, ' ', '');
>
> See http://dev.mysql.com/doc/refman/5.0/en/string-functions.html
>
> Regards,
> Bill K.