TRUNCATE(123.456, 1) = 123.4
TRUNCATE(123.456, 0) = 123
TRUNCATE(123.456, -1) = 120
TRUNCATE(-123.456, 1) = -123.4
TRUNCATE 不會四捨五入,請用 ROUND 代替
ROUND(345.678, 1) = 345.7
ROUND(344.678, -1) = 340
ROUND(345.678, -1) = 350
TRUNCATE(123.456, 1) = 123.4
TRUNCATE(123.456, 0) = 123
TRUNCATE(123.456, -1) = 120
TRUNCATE(-123.456, 1) = -123.4
TRUNCATE 不會四捨五入,請用 ROUND 代替
ROUND(345.678, 1) = 345.7
ROUND(344.678, -1) = 340
ROUND(345.678, -1) = 350
這些半形字元會影響到解析,所以用了以下方法。
UPDATE TWEVTCAL_ACTIVITY SET content=REPLACE(content, '"', '”'); UPDATE TWEVTCAL_ACTIVITY SET content=REPLACE(content, '&', '&'); UPDATE TWEVTCAL_ACTIVITY SET content=REPLACE(content, "'", "’"); UPDATE TWEVTCAL_ACTIVITY SET content=REPLACE(content, '<', '<'); UPDATE TWEVTCAL_ACTIVITY SET content=REPLACE(content, '>', '>');