insert into users
SELECT daihao as dh,mingcheng as mc,jibie as jb,dishi as ds,xianqu as xq,kaodian as kd,danwei as dw,kouling as psw,'1' as zt
from xt_yonghu
跟SQL SERVER的不一样啊
分太少了,不好意思啊,没分用了
3 个解决方案
#1
这个语句应该可以啊,什么错误提示?
#2
user表的结构要对应后面的查询字段,如果是部份字段要
insert into users(dh,mc,jb,ds,...)
SELECT daihao as dh,mingcheng as mc,jibie as jb,dishi as ds,xianqu as xq,kaodian as kd,danwei as dw,kouling as psw,'1' as zt
from xt_yonghu
insert into users(dh,mc,jb,ds,...)
SELECT daihao as dh,mingcheng as mc,jibie as jb,dishi as ds,xianqu as xq,kaodian as kd,danwei as dw,kouling as psw,'1' as zt
from xt_yonghu
#3
前后字段匹配么? users中的字段是不是个数或者类型和后面查询出的不匹配
#1
这个语句应该可以啊,什么错误提示?
#2
user表的结构要对应后面的查询字段,如果是部份字段要
insert into users(dh,mc,jb,ds,...)
SELECT daihao as dh,mingcheng as mc,jibie as jb,dishi as ds,xianqu as xq,kaodian as kd,danwei as dw,kouling as psw,'1' as zt
from xt_yonghu
insert into users(dh,mc,jb,ds,...)
SELECT daihao as dh,mingcheng as mc,jibie as jb,dishi as ds,xianqu as xq,kaodian as kd,danwei as dw,kouling as psw,'1' as zt
from xt_yonghu
#3
前后字段匹配么? users中的字段是不是个数或者类型和后面查询出的不匹配