select id, public.st_asewkt(geom) AS geom, upload_id, geom_json, sort, geom_area from t_geom_db_details
insert into t_geom_db_details
id,
geom,
upload_id,
geom_json,
sort,
geom_area,
#{id},
public.st_transform(public.st_geomfromewkt(#{geom}), #{shpDbSRID}),
#{uploadId},
#{geomJson},
#{sort},
public.st_area(public.st_transform(public.st_geomfromewkt(#{geom}), #{shpAreaSRID})
::PUBLIC.geography
),
update t_geom_db_details
geom = #{geom},
upload_id = #{uploadId},
geom_json = #{geomJson},
sort = #{sort},
geom_area = #{geomArea},
where id = #{id}
delete from t_geom_db_details where id = #{id}
delete from t_geom_db_details where id in
#{id}
INSERT INTO vector.djzq (bsm, ysdm, djzqdm, djzqmc, bz, geom, valid_flag)
VALUES
(
#{item.bsm},
#{item.ysdm},
#{item.djzqdm},
#{item.djzqmc},
#{item.projectid},
public.st_transform(public.st_geomfromewkt(#{item.the_geom}), #{shpDbSRID})
null
,
0
)
INSERT INTO vector.djq (bsm, ysdm, djqdm, djqmc, bz, geom, valid_flag)
VALUES
(
#{item.bsm},
#{item.ysdm},
#{item.djqdm},
#{item.djqmc},
#{item.projectid},
public.st_transform(public.st_geomfromewkt(#{item.the_geom}), #{shpDbSRID})
null
,
0
)
INSERT INTO vector.fw (
objectid,
bsm,
ysdm,
bdcdyh,
zddm,
xzqdm,
zh,
xmmc,
jzwmc,
jgrq,
jzwgd,
zzdmj,
zydmj,
ycjzmj,
scjzmj,
jzwjbyt,
zcs,
dscs,
dxcs,
dxsd,
ghyt,
fwjg,
zts,
bz,
zt,
tstybm,
zrzh,
lplb,
zl,
bgjzxx,
bgtsxx,
rkxh,
rkr,
rksj,
ytmc,
dah,
srctable,
from_id,
to_id,
projectid,
shape_area,
shape_len,
geom
)
VALUES
(
#{item.objectid},
#{item.bsm},
#{item.ysdm},
#{item.bdcdyh},
#{item.zddm},
#{item.xzqdm},
#{item.zh},
#{item.xmmc},
#{item.jzwmc},
#{item.jgrq},
#{item.jzwgd},
#{item.zzdmj},
#{item.zydmj},
#{item.ycjzmj},
#{item.scjzmj},
#{item.jzwjbyt},
#{item.zcs},
#{item.dscs},
#{item.dxcs},
#{item.dxsd},
#{item.ghyt},
#{item.fwjg},
#{item.zts},
#{item.bz},
#{item.zt},
#{item.tstybm},
#{item.zrzh},
#{item.lplb},
#{item.zl},
#{item.bgjzxx},
#{item.bgtsxx},
#{item.rkxh},
#{item.rkr},
#{item.rksj},
#{item.ytmc},
#{item.dah},
#{item.srctable},
#{item.from_id},
#{item.to_id},
#{item.projectid},
#{item.shape_area},
#{item.shape_len},
public.st_transform(
public.st_geomfromewkt(#{item.the_geom}),
#{shpDbSRID}
)
null
)
INSERT INTO vector.zd_shp (
objectid,bsm,ysdm,bdcdyh,zddm,zdtzm,zl,midw,
zdmj,yt,dj,jg,qllx,qlxz,qlsdfs,rjl,jzmd,jzxg,
zdszd,zdszn,zdszx,zdszb,tfh,djh,qlrmc,jzmj,jzwzdmj,
zt,bhyy,bhnr,djsj,dbr,fj,tstybm,xzqdm,sjzdtybm,
fzmj,ybzddm,jzlb,syqx,qsrq,zzrq,bgjzxx,bgtsxx,
dah,rkxh,rkr,rksj,ytmc,zdt,bz,srctable,
from_id,to_id,projectid,txzt,jdzt,ywh,bdcqzh,
ydyhfl,shape_area,shape_len,geom
)
VALUES
(
#{item.objectid},
#{item.bsm},
#{item.ysdm},
#{item.bdcdyh},
#{item.zddm},
#{item.zdtzm},
#{item.zl},
#{item.midw},
#{item.zdmj},
#{item.yt},
#{item.dj},
#{item.jg},
#{item.qllx},
#{item.qlxz},
#{item.qlsdfs},
#{item.rjl},
#{item.jzmd},
#{item.jzxg},
#{item.zdszd},
#{item.zdszn},
#{item.zdszx},
#{item.zdszb},
#{item.tfh},
#{item.djh},
#{item.qlrmc},
#{item.jzmj},
#{item.jzwzdmj},
#{item.zt},
#{item.bhyy},
#{item.bhnr},
#{item.djsj},
#{item.dbr},
#{item.fj},
#{item.tstybm},
#{item.xzqdm},
#{item.sjzdtybm},
#{item.fzmj},
#{item.ybzddm},
#{item.jzlb},
#{item.syqx},
#{item.qsrq},
#{item.zzrq},
#{item.bgjzxx},
#{item.bgtsxx},
#{item.dah},
#{item.rkxh},
#{item.rkr},
#{item.rksj},
#{item.ytmc},
#{item.zdt},
#{item.bz},
#{item.srctable},
#{item.from_id},
#{item.to_id},
#{item.projectid},
#{item.txzt},
#{item.jdzt},
#{item.ywh},
#{item.bdcqzh},
#{item.ydyhfl},
#{item.shape_area},
#{item.shape_len},
public.st_transform(
public.st_geomfromewkt(#{item.the_geom}),
#{shpDbSRID}
)
null
)
INSERT INTO vector.${tableName} (
${key}
)
VALUES (
public.st_transform(public.st_geomfromewkt(#{value}), #{shpDbSRID})
#{value}
)