我正在尝试在单个表中调整多行夏令时。我需要在发现错误之前写入的所有记录中增加一个小时。我收到错误
Subquery returns more than 1 value. This is not permitted when the subquery follows =, != etc
我明白它在告诉我什么,我只是想不出解决办法。这就是我想要做的:
UPDATE Table
SET LocalDateTime = LocalDateTime + '1:00:00'
WHERE (DateWritten > '3/10/13') AND (DateWritten < '3/11/13 7:00:00') AND (varCharColumn <> 'aString')
我也尝试了这种变化并收到了同样的错误。
UPDATE Table
SET LocalDateTime = LocalDateTime + '1:00:00'
WHERE DateWritten IN (SELECT DateWritten FROM Table WHERE (same clause as above))