提交 043a97a1 编写于 作者: zc's avatar zc

update:关系型数据库模式下,结果入库调整

上级 1665582f
...@@ -24,8 +24,8 @@ ...@@ -24,8 +24,8 @@
#{item.domainsField},#{item.timeField}, #{item.ext1Field}, #{item.ext2Field},#{item.businessCat},#{item.systemId} ) #{item.domainsField},#{item.timeField}, #{item.ext1Field}, #{item.ext2Field},#{item.businessCat},#{item.systemId} )
</foreach> </foreach>
ON DUPLICATE KEY UPDATE ON DUPLICATE KEY UPDATE
updatedate=now(),retvalue=values(retValue), metricField=values(metricField),domainsField=values(domainsField), ru_execresultname=values(ru_execresultname),rulename=values(rulename),updatedate=now(),retvalue=values(retValue), metricField=values(metricField),domainsField=values(domainsField),timefield=values(timefield),
ext1Field=values(ext1Field),ext2Field=values(ext2Field), businessCat=values(businessCat) ext1Field=values(ext1Field),ext2Field=values(ext2Field), businessCat=values(businessCat),systemid=values(systemid)
</insert> </insert>
<insert id="replaceBatch" parameterType="java.util.List" databaseId="postgresql"> <insert id="replaceBatch" parameterType="java.util.List" databaseId="postgresql">
...@@ -37,8 +37,8 @@ ...@@ -37,8 +37,8 @@
#{item.domainsField},#{item.timeField}, #{item.ext1Field}, #{item.ext2Field},#{item.businessCat},#{item.systemId} ) #{item.domainsField},#{item.timeField}, #{item.ext1Field}, #{item.ext2Field},#{item.businessCat},#{item.systemId} )
</foreach> </foreach>
ON conflict(ru_execresultid) DO UPDATE set ON conflict(ru_execresultid) DO UPDATE set
updatedate=current_timestamp, retvalue=excluded.retValue, metricfield=excluded.metricField, domainsfield=excluded.domainsField, ru_execresultname=excluded.ru_execresultname,rulename=excluded.rulename,updatedate=current_timestamp, retvalue=excluded.retValue, metricfield=excluded.metricField, domainsfield=excluded.domainsField,timefield=excluded.timefield,
ext1field=excluded.ext1Field,ext2field=excluded.ext2Field, businesscat=excluded.businessCat ext1field=excluded.ext1Field,ext2field=excluded.ext2Field, businesscat=excluded.businessCat,systemid=excluded.systemid
</insert> </insert>
...@@ -67,7 +67,7 @@ ...@@ -67,7 +67,7 @@
#{item.domainsField},#{item.timeField}, #{item.ext1Field}, #{item.ext2Field},#{item.businessCat},#{item.systemId} ) #{item.domainsField},#{item.timeField}, #{item.ext1Field}, #{item.ext2Field},#{item.businessCat},#{item.systemId} )
</foreach> </foreach>
ON conflict(ru_execresultid) DO UPDATE set ON conflict(ru_execresultid) DO UPDATE set
ru_execresultname=excluded.name, updatedate=current_timestamp, ruleid=excluded.ruleId, rulename=excluded.ruleName, ru_execresultname=excluded.ru_execresultname, updatedate=current_timestamp, ruleid=excluded.ruleId, rulename=excluded.ruleName,
retvalue=excluded.retValue, keyvaluefield=excluded.keyValueField, dimfield=excluded.dimField, metricfield=excluded.metricField,domainsfield=excluded.domainsField,timefield=excluded.timeField, retvalue=excluded.retValue, keyvaluefield=excluded.keyValueField, dimfield=excluded.dimField, metricfield=excluded.metricField,domainsfield=excluded.domainsField,timefield=excluded.timeField,
ext1field=excluded.ext1Field,ext2field=excluded.ext2Field, businesscat=excluded.businessCat,systemid=excluded.systemId ext1field=excluded.ext1Field,ext2field=excluded.ext2Field, businesscat=excluded.businessCat,systemid=excluded.systemId
</insert> </insert>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册