本帖最后由 flygoodkiller 于 2021-5-21 16:45 编辑
with cte as(
SELECT 编号,客户,负责人,订单金额,null as 日期,null as 金额,null as 员工,null as 费用类型,null as 外联单位,null as 凭证号,null as 摘要,null as 备注 FROM "xm"
union all
SELECT 编号,null as 客户,null as 负责人,null as 订单金额,日期,金额,员工,费用类型,null as 外联单位,null as 凭证号,null as 摘要,备注 FROM "fy1"
union all
SELECT 编号,null as 客户,null as 负责人,null as 订单金额,null as 日期,金额,员工,费用类型,外联单位,凭证号,摘要,备注 FROM "fy2"
union all
SELECT 编号,null as 客户,null as 负责人,null as 订单金额,日期,金额,null as 员工,null as 费用类型,null as 外联单位,null as 凭证号,null as 摘要,null as 备注 FROM "sr"
)
SELECT * FROM cte;
|