加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 站长学院 > MsSql教程 > 正文

sql – 将一个字段从表复制到同一个表中的另一个字段

发布时间:2020-12-12 06:50:26 所属栏目:MsSql教程 来源:网络整理
导读:我使用此查询从同一个表中复制一个完整列: UPDATE 'content_type_chapter' SET 'field_chapternumbersort2_value' = 'field_chapternumbersort_value' 但是我收到了这个错误. You have an error in your SQL syntax; check the manual that corresponds to y
我使用此查询从同一个表中复制一个完整列:
UPDATE 'content_type_chapter' 
   SET 'field_chapternumbersort2_value' = 'field_chapternumbersort_value'

但是我收到了这个错误.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ”content_type_chapter’ SET ‘field_chapternumbersort2_value’=’field_chapternumber’ at line 1

可能有什么不对,我无法做对.

解决方法

只需将引号从字段名称中删除,否则它会认为您正在给它字符串

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读