我正在使用SQL Server 2008并且必须更新一个包含此格式值的字段(FIELD_NAM):
我尝试了以下声明:
UPDATE Table
SET FIELD = 'ttttt', 'kkkk', 'mmmmmm'
WHERE ID = 1
(只需要更新一行和一个字段/列) 我得到的错误是
'ttttt'附近的语法不正确
答案 0 :(得分:2)
update "table"
set field = '''ttttt'', ''kkkk'', ''mmmmmm'''
where id = 1
;
答案 1 :(得分:0)
UPDATE Table
SET FIELD = 'ttttt\', \'kkkk\', \'mmmmmm'
WHERE ID = 1
OR
UPDATE Table
SET FIELD = 'ttttt'', ''kkkk'', ''mmmmmm'
WHERE ID = 1