在ODS层建了一张表,准备将原库的数据同步过来,字段都是一样,唯一的区别就是需要建立联合主键,但是同步时报错了ODS建表语句:create table SK_SHIKONG_FR_QYXSQS(startdate varchar(10) not null ,--数据开始日期enddate varchar(10) not null ,--数据结束日期ssbm varchar(20) not null , --所属部门quyufl varchar(20) not null,--区域分类lastyearhsje decimal(18,3) ,--去年含税金额lastyearhsml decimal(18,3) ,--去年含税毛利lastyearwsje decimal(18,3) ,--去年无税金额lastyearwsml decimal(18,3) ,--去年无税毛利thisyearhsje decimal(18,3) ,--下面的是今年thisyearhsml decimal(18,3) ,thisyearwsje decimal(18,3) ,thisyearwsml decimal(18,3),hsjebalance decimal(18,3),--含税金额差额wsjebalance decimal(18,3),--无税金额差额hsmlbalance decimal(18,3),--含税毛利差额wsmlbalance decimal(18,3),--无税毛利差额hsjezzl decimal(14,3),--含税金额增长率wsjezzl decimal(14,3),--无税金额增长率hsmlzzl decimal(14,3),--含税毛利增长率wsmlzzl decimal(14,3),--无税毛利增长率hsjetrend varchar(5),--含税金额趋势wsjetrend varchar(5),--无税金额趋势hsmltrend varchar(5),--含税毛利趋势wsmltrend varchar(5),--无税毛利趋势createtime date --创建时间)alter table SK_SHIKONG_FR_QYXSQS add constraint quyufl primary key (startdate,enddate,ssbm,quyufl)