update 表名 set 字段1='值',字段2='值' where 字段1='值' and 字段2='值';
加一个分号看看!!

解决方案 »

  1.   

    where is 'gz'?
    我把字段1和字段2都加了所引。字段1并且是关键字.
      

  2.   

    where is 'gz'?
    我把字段1和字段2都加了所引。字段1并且是关键字. 
      

  3.   

    update province set name='湖北',short='鄂' where name='湖南' and short='鄂'
      

  4.   

    short 是关键字,你把这个字段改成其他的名字看看,比如:sht,肯定没问题!
      

  5.   

    错。name是关銉字。
    但我现在把所引和关键字都去掉了,还是不行。
    sql语句是:
    update province set name='湖北',short='鄂' where name='湖南' and short='鄂'
    提示:update语句的语法错误
      

  6.   

    update province set [name]='湖北',[short]='鄂' where [name]='湖南' and [short]='鄂'
      

  7.   

    我试过啦,把short改称sht之类的就能通过!
      

  8.   

    你得把你得代码公开出来,我觉得你可能是SQL语句组合是出的错误,一定要注意“”‘’这4个标点的运用
      

  9.   

    我不信。为什么把short改成sht就可以?为什么?为什么?
    why?
      

  10.   

    update province set [name]='value',[short]='value' where [name]='value' and [short]='value'
      

  11.   

    象name、short等等系统保留字必须要加括号,否则系统会认为是语法错误,还有一些特殊的字段名称如中间有分隔符如[province name]也必须要加括号
      

  12.   

    比如select province name from province 肯定会提示语法出错,正确的应该是select [province name] from province