2012-01-26 69 views

回答

2
update table1 set col5 = 'x' + col5 
+0

真快:) –

+0

它比使用CONCAT快? – David19801

+0

我沒有嘗試它,但我想它會被優化到相同的 –

4
update table1 
set col5 = CONCAT('x', col5) 
where col5 NOT LIKE 'x%'; -- optional, depending on circumstances 
1
UPDATE table1 SET col5 = CONCAT('x', col5); 
相關問題