create table A
(
  id identity int,
  ...
)

解决方案 »

  1.   

    why not use Int?
    not know what you say.
      

  2.   

    convert it to a int type ,you can use system function , for instance : cast,convert
      

  3.   

    update tbleName set columnName = cast(column as int) + 1 where 1=1i suggest that set the column type as a int type is a better way
      

  4.   

    为什么 不 使用int 类型呢? 这样不是更 方便?
    加到10就不行?
    难道你没有定义 varchar的大小 那么默认只有一位
    10已经2位数了 当然不行.
      
    *****************************************************************************
    没事来逛逛 我的BLOG
    http://blog.csdn.net/hertcloud/
      

  5.   

    最好用int identity
    为什么加到10就不行了??是长度不够?还是因为由于是char自动加到后面去了?如果是长度不够,回大长度,如果是char的问题,转化成int再加
    cast(id as int)+ 1
      

  6.   

    create table A
    (
      id identity int,
      ...
    )
      

  7.   

    Hava a try for the type of int
      

  8.   

    varchar默认只有一位,用上面说的int型就可以
      

  9.   

    Why I can't type chinese?You can try int
      

  10.   

    int
                                   int
                                   int
      intint      intintintint   intintint
        int        int    int      int
        int        int    int      int
        int        int    int      int
      intintint    intintint nt intint
      

  11.   

    如果字段数据本身没有意义,只是想作为主键,用自动编号.
    varchar类型定义的时候可能长度为1,所以不能增长两位的10.
      

  12.   

    Hava a try for the type of int
      

  13.   

    create table A
    (
      id identity int,
      ...
    )
      

  14.   

    hertcloud(·£孙子兵法£·) 
    cpp2017(慕白兄)
    同意