你看一下你更新字段的类型啊,为enum,字符串对象类型,需要加引号的update order_test set order_state=‘30’

解决方案 »

  1.   

    ENUM('value1','value2',...) [CHARACTER SET charset_name] [COLLATE collation_name] An enumeration. A string object that can have only one value, chosen from the list of values 'value1', 'value2', ..., NULL or the special '' error value. An ENUM column can have a maximum of 65,535 distinct values. ENUM values are represented internally as integers. ENUM:字符型 
    update order_test set order_state='30' where order_id=xxx
      

  2.   

    `order_state` enum('0','10','20','30','50','60','40') NOT NULL DEFAULT '20' COMMENT '订单状态:0(已取消)10(默认):未付款;20:已付款;30:已发货;50:供应商发货;60:平台收货40:已收货;',
    注意字段类型定义。