字符去掉空格

 

一、去掉数据库字段的先后空格,ltrim 去掉左边的空格,rtrim去掉右边的空格。sql

update tableName t set t.columnName = trim(t.columnName);