1

尝试更新表,以便将字段的内容更改为大写。

UPDATE `schools` SET `postcode` = 
UPPER(
(SELECT `postcode` FROM `schools` WHERE 1)
)

试过这个

UPDATE `schools` SET `postcode` = 
UPPER( 
SELECT `postcode` FROM  (SELECT * FROM `schools`) AS x WHERE `postcode`!=''
) WHERE 1

我知道这是可能的,但不能改变这种语法

4

2 回答 2

1

试试这个:

UPDATE `schools` 
SET `postcode` =UPPER(`postcode`)
于 2012-09-06T13:00:12.617 回答
0


你应该这样尝试

UPDATE schools SET postcode =UPPER(SELECT `postcode` FROM `schools` WHERE ur_column = values)
于 2012-09-06T13:08:55.577 回答