且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

MySQL 将所有空格替换为 -

更新时间:2021-10-05 23:29:28

这可以通过以下 MySQL 函数来实现:

This can be achieved with the following MySQL Function:

SELECT REPLACE( table.field, ' ', '-' ) FROM table;

这应该将所有空格替换为 -

This should replace all the whitespace to a -