去除tab空格 sql

来源:百度知道 编辑:UC知道 时间:2024/06/24 11:22:16
在mysql 去掉tab空格
用什么来表示 tab空格?

MySQL将栏位里的tab字元清除
MySQL里的Tab字元为 \t使用以下SQL即可将将栏位里的tab字元清除update `scott` set `AA`=replace(`AA`,'\t','') WHERE `AA` like '%\t%

去掉隐藏的换行符。
update tb1 set test1= replace(test1 ,'\n\r','');
update tb1 set test1= replace(test1 ,'\n','');
update tb1 set test1= replace(test1 ,'\r','');

select name from 表名;

--比如说name字段两端存在空格。

select trim(name) from 表名;

--查询出来name字段的值的空格就被去掉了。