Oracle一条数据多表连插
insert all into T_TRAIN_MARSHALLING
<trim prefix="(GKEY," suffix=")" suffixOverrides=",">
<if test="ID != null and ID != '' ">ID,</if>
<if test="1 == 1">TRAIN_NUM,</if>
<if test="PRE_TRAIN_NUMBER != null and PRE_TRAIN_NUMBER != '' ">PRE_TRAIN_NUMBER,</if>
<if test="TRAIN__WAGON_INFORMATION_FK_GKEY != null and TRAIN__WAGON_INFORMATION_FK_GKEY != '' ">TRAIN__WAGON_INFORMATION_FK_GKEY,</if>
<if test="1 == 1">WAGON_NUMBER,</if>
<if test="WAGON_TYPE != null and WAGON_TYPE != '' ">WAGON_TYPE,</if>
<if test="CHANGE_LENGTH != null and CHANGE_LENGTH != '' ">CHANGE_LENGTH,</if>
<if test="SELF_WEIGHT != null and SELF_WEIGHT != '' ">SELF_WEIGHT,</if>
<if test="LOAD != null and LOAD != '' ">LOAD,</if>
<if test="NET_WEIGHT != null and NET_WEIGHT != '' ">NET_WEIGHT,</if>
<if test="Estimated_costs != null and Estimated_costs != '' ">Estimated_costs,</if>
<if test="RECEIVE_SEND != null and RECEIVE_SEND != '' ">RECEIVE_SEND,</if>
<if test="SEND_STATION != null and SEND_STATION != '' ">SEND_STATION,</if>
<if test="ARRIVAL_STATION != null and ARRIVAL_STATION != '' ">ARRIVAL_STATION,</if>
<if test="VARIETY != null and VARIETY != '' ">VARIETY,</if>
<if test="CARGO_TYPES != null and CARGO_TYPES != '' ">CARGO_TYPES,</if>
<if test="TICKET_SENDER != null and TICKET_SENDER != '' ">TICKET_SENDER,</if>
<if test="SENDER != null and SENDER != '' ">SENDER,</if>
<if test="TICKET_CONSIGNEE != null and TICKET_CONSIGNEE != '' ">TICKET_CONSIGNEE,</if>
<if test="CONSIGNEE != null and CONSIGNEE != '' ">CONSIGNEE,</if>
<if test="TICKET != null and TICKET != '' ">TICKET,</if>
<if test="BELONG != null and BELONG != '' ">BELONG,</if>
<if test="WEIGHT != null and WEIGHT != '' ">WEIGHT,</if>
<if test="ARMY != null and ARMY != '' ">ARMY,</if>
<if test="BACK != null and BACK != '' ">BACK,</if>
<if test="Code != null and Code != '' ">Code,</if>
<if test="WHOLE != null and WHOLE != '' ">WHOLE,</if>
<if test="NOTE != null and NOTE != '' ">NOTE,</if>
<if test="REMARK != null and REMARK != '' ">REMARK,</if>
<if test="CREATED != null and CREATED != '' ">CREATED,</if>
<if test="CREATOR != null and CREATOR != '' ">CREATOR,</if>
<if test="CHANGED != null and CHANGED != '' ">CHANGED,</if>
<if test="CHANGER != null and CHANGER != '' ">CHANGER,</if>
<if test="IS_DELETED != null and IS_DELETED != '' ">IS_DELETED</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">sys_guid(),
<if test="ID != null and ID != '' ">#{ID},</if>
<if test="1 == 1">#{TRAIN_NUM},</if>
<if test="PRE_TRAIN_NUMBER != null and PRE_TRAIN_NUMBER != '' ">#{PRE_TRAIN_NUMBER},</if>
<if test="TRAIN__WAGON_INFORMATION_FK_GKEY != null and TRAIN__WAGON_INFORMATION_FK_GKEY != '' ">#{TRAIN__WAGON_INFORMATION_FK_GKEY},</if>
<if test="1 == 1">#{WAGON_NUMBER},</if>
<if test="WAGON_TYPE != null and WAGON_TYPE != '' ">#{WAGON_TYPE},</if>
<if test="CHANGE_LENGTH != null and CHANGE_LENGTH != '' ">#{CHANGE_LENGTH},</if>
<if test="SELF_WEIGHT != null and SELF_WEIGHT != '' ">#{SELF_WEIGHT},</if>
<if test="LOAD != null and LOAD != '' ">#{LOAD},</if>
<if test="NET_WEIGHT != null and NET_WEIGHT != '' ">#{NET_WEIGHT},</if>
<if test="Estimated_costs != null and Estimated_costs != '' ">#{Estimated_costs},</if>
<if test="RECEIVE_SEND != null and RECEIVE_SEND != '' ">#{RECEIVE_SEND},</if>
<if test="SEND_STATION != null and SEND_STATION != '' ">#{SEND_STATION},</if>
<if test="ARRIVAL_STATION != null and ARRIVAL_STATION != '' ">#{ARRIVAL_STATION},</if>
<if test="VARIETY != null and VARIETY != '' ">#{VARIETY},</if>
<if test="CARGO_TYPES != null and CARGO_TYPES != '' ">#{CARGO_TYPES},</if>
<if test="TICKET_SENDER != null and TICKET_SENDER != '' ">#{TICKET_SENDER},</if>
<if test="SENDER != null and SENDER != '' ">#{SENDER},</if>
<if test="TICKET_CONSIGNEE != null and TICKET_CONSIGNEE != '' ">#{TICKET_CONSIGNEE},</if>
<if test="CONSIGNEE != null and CONSIGNEE != '' ">#{CONSIGNEE},</if>
<if test="TICKET != null and TICKET != '' ">#{TICKET},</if>
<if test="BELONG != null and BELONG != '' ">#{BELONG},</if>
<if test="WEIGHT != null and WEIGHT != '' ">#{WEIGHT},</if>
<if test="ARMY != null and ARMY != '' ">#{ARMY},</if>
<if test="BACK != null and BACK != '' ">#{BACK},</if>
<if test="Code != null and Code != '' ">#{Code},</if>
<if test="WHOLE != null and WHOLE != '' ">#{WHOLE},</if>
<if test="NOTE != null and NOTE != '' ">#{NOTE},</if>
<if test="REMARK != null and REMARK != '' ">#{REMARK},</if>
<if test="CREATED != null and CREATED != '' ">#{CREATED},</if>
<if test="CREATOR != null and CREATOR != '' ">#{CREATOR},</if>
<if test="CHANGED != null and CHANGED != '' ">#{CHANGED},</if>
<if test="CHANGER != null and CHANGER != '' ">#{CHANGER},</if>
<if test="IS_DELETED != null and IS_DELETED != '' ">#{IS_DELETED}</if>
</trim>
into T_TRAIN_WAGON_INFORMATION
<trim prefix="(GKEY," suffix=")" suffixOverrides=",">
<if test="1 == 1">WAGON_NUMBER,</if>
<if test="WAGON_TYPE != null and WAGON_TYPE != '' ">WAGON_TYPE,</if>
<if test="CHANGE_LENGTH != null and CHANGE_LENGTH != '' ">CHANGE_LENGTH,</if>
<if test="SELF_WEIGHT != null and SELF_WEIGHT != '' ">SELF_WEIGHT,</if>
<if test="LOAD != null and LOAD != '' ">LOAD,</if>
<if test="REMARK != null and REMARK != '' ">REMARK,</if>
<if test="CREATED != null and CREATED != '' ">CREATED,</if>
<if test="CREATOR != null and CREATOR != '' ">CREATOR,</if>
<if test="CHANGED != null and CHANGED != '' ">CHANGED,</if>
<if test="CHANGER != null and CHANGER != '' ">CHANGER,</if>
<if test="IS_DELETED != null and IS_DELETED != '' ">IS_DELETED</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">sys_guid(),
<if test="1 == 1">#{WAGON_NUMBER},</if>
<if test="WAGON_TYPE != null and WAGON_TYPE != '' ">#{WAGON_TYPE},</if>
<if test="CHANGE_LENGTH != null and CHANGE_LENGTH != '' ">#{CHANGE_LENGTH},</if>
<if test="SELF_WEIGHT != null and SELF_WEIGHT != '' ">#{SELF_WEIGHT},</if>
<if test="LOAD != null and LOAD != '' ">#{LOAD},</if>
<if test="REMARK != null and REMARK != '' ">#{REMARK},</if>
<if test="CREATED != null and CREATED != '' ">#{CREATED},</if>
<if test="CREATOR != null and CREATOR != '' ">#{CREATOR},</if>
<if test="CHANGED != null and CHANGED != '' ">#{CHANGED},</if>
<if test="CHANGER != null and CHANGER != '' ">#{CHANGER},</if>
<if test="IS_DELETED != null and IS_DELETED != '' ">#{IS_DELETED}</if>
</trim>
insert all into T_TRAIN_MARSHALLING
<trim prefix="(GKEY," suffix=")" suffixOverrides=",">
<if test="ID != null and ID != '' ">ID,</if>
<if test="1 == 1">TRAIN_NUM,</if>
<if test="PRE_TRAIN_NUMBER != null and PRE_TRAIN_NUMBER != '' ">PRE_TRAIN_NUMBER,</if>
<if test="TRAIN__WAGON_INFORMATION_FK_GKEY != null and TRAIN__WAGON_INFORMATION_FK_GKEY != '' ">TRAIN__WAGON_INFORMATION_FK_GKEY,</if>
<if test="1 == 1">WAGON_NUMBER,</if>
<if test="WAGON_TYPE != null and WAGON_TYPE != '' ">WAGON_TYPE,</if>
<if test="CHANGE_LENGTH != null and CHANGE_LENGTH != '' ">CHANGE_LENGTH,</if>
<if test="SELF_WEIGHT != null and SELF_WEIGHT != '' ">SELF_WEIGHT,</if>
<if test="LOAD != null and LOAD != '' ">LOAD,</if>
<if test="NET_WEIGHT != null and NET_WEIGHT != '' ">NET_WEIGHT,</if>
<if test="Estimated_costs != null and Estimated_costs != '' ">Estimated_costs,</if>
<if test="RECEIVE_SEND != null and RECEIVE_SEND != '' ">RECEIVE_SEND,</if>
<if test="SEND_STATION != null and SEND_STATION != '' ">SEND_STATION,</if>
<if test="ARRIVAL_STATION != null and ARRIVAL_STATION != '' ">ARRIVAL_STATION,</if>
<if test="VARIETY != null and VARIETY != '' ">VARIETY,</if>
<if test="CARGO_TYPES != null and CARGO_TYPES != '' ">CARGO_TYPES,</if>
<if test="TICKET_SENDER != null and TICKET_SENDER != '' ">TICKET_SENDER,</if>
<if test="SENDER != null and SENDER != '' ">SENDER,</if>
<if test="TICKET_CONSIGNEE != null and TICKET_CONSIGNEE != '' ">TICKET_CONSIGNEE,</if>
<if test="CONSIGNEE != null and CONSIGNEE != '' ">CONSIGNEE,</if>
<if test="TICKET != null and TICKET != '' ">TICKET,</if>
<if test="BELONG != null and BELONG != '' ">BELONG,</if>
<if test="WEIGHT != null and WEIGHT != '' ">WEIGHT,</if>
<if test="ARMY != null and ARMY != '' ">ARMY,</if>
<if test="BACK != null and BACK != '' ">BACK,</if>
<if test="Code != null and Code != '' ">Code,</if>
<if test="WHOLE != null and WHOLE != '' ">WHOLE,</if>
<if test="NOTE != null and NOTE != '' ">NOTE,</if>
<if test="REMARK != null and REMARK != '' ">REMARK,</if>
<if test="CREATED != null and CREATED != '' ">CREATED,</if>
<if test="CREATOR != null and CREATOR != '' ">CREATOR,</if>
<if test="CHANGED != null and CHANGED != '' ">CHANGED,</if>
<if test="CHANGER != null and CHANGER != '' ">CHANGER,</if>
<if test="IS_DELETED != null and IS_DELETED != '' ">IS_DELETED</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">sys_guid(),
<if test="ID != null and ID != '' ">#{ID},</if>
<if test="1 == 1">#{TRAIN_NUM},</if>
<if test="PRE_TRAIN_NUMBER != null and PRE_TRAIN_NUMBER != '' ">#{PRE_TRAIN_NUMBER},</if>
<if test="TRAIN__WAGON_INFORMATION_FK_GKEY != null and TRAIN__WAGON_INFORMATION_FK_GKEY != '' ">#{TRAIN__WAGON_INFORMATION_FK_GKEY},</if>
<if test="1 == 1">#{WAGON_NUMBER},</if>
<if test="WAGON_TYPE != null and WAGON_TYPE != '' ">#{WAGON_TYPE},</if>
<if test="CHANGE_LENGTH != null and CHANGE_LENGTH != '' ">#{CHANGE_LENGTH},</if>
<if test="SELF_WEIGHT != null and SELF_WEIGHT != '' ">#{SELF_WEIGHT},</if>
<if test="LOAD != null and LOAD != '' ">#{LOAD},</if>
<if test="NET_WEIGHT != null and NET_WEIGHT != '' ">#{NET_WEIGHT},</if>
<if test="Estimated_costs != null and Estimated_costs != '' ">#{Estimated_costs},</if>
<if test="RECEIVE_SEND != null and RECEIVE_SEND != '' ">#{RECEIVE_SEND},</if>
<if test="SEND_STATION != null and SEND_STATION != '' ">#{SEND_STATION},</if>
<if test="ARRIVAL_STATION != null and ARRIVAL_STATION != '' ">#{ARRIVAL_STATION},</if>
<if test="VARIETY != null and VARIETY != '' ">#{VARIETY},</if>
<if test="CARGO_TYPES != null and CARGO_TYPES != '' ">#{CARGO_TYPES},</if>
<if test="TICKET_SENDER != null and TICKET_SENDER != '' ">#{TICKET_SENDER},</if>
<if test="SENDER != null and SENDER != '' ">#{SENDER},</if>
<if test="TICKET_CONSIGNEE != null and TICKET_CONSIGNEE != '' ">#{TICKET_CONSIGNEE},</if>
<if test="CONSIGNEE != null and CONSIGNEE != '' ">#{CONSIGNEE},</if>
<if test="TICKET != null and TICKET != '' ">#{TICKET},</if>
<if test="BELONG != null and BELONG != '' ">#{BELONG},</if>
<if test="WEIGHT != null and WEIGHT != '' ">#{WEIGHT},</if>
<if test="ARMY != null and ARMY != '' ">#{ARMY},</if>
<if test="BACK != null and BACK != '' ">#{BACK},</if>
<if test="Code != null and Code != '' ">#{Code},</if>
<if test="WHOLE != null and WHOLE != '' ">#{WHOLE},</if>
<if test="NOTE != null and NOTE != '' ">#{NOTE},</if>
<if test="REMARK != null and REMARK != '' ">#{REMARK},</if>
<if test="CREATED != null and CREATED != '' ">#{CREATED},</if>
<if test="CREATOR != null and CREATOR != '' ">#{CREATOR},</if>
<if test="CHANGED != null and CHANGED != '' ">#{CHANGED},</if>
<if test="CHANGER != null and CHANGER != '' ">#{CHANGER},</if>
<if test="IS_DELETED != null and IS_DELETED != '' ">#{IS_DELETED}</if>
</trim>
into T_TRAIN_WAGON_INFORMATION
<trim prefix="(GKEY," suffix=")" suffixOverrides=",">
<if test="1 == 1">WAGON_NUMBER,</if>
<if test="WAGON_TYPE != null and WAGON_TYPE != '' ">WAGON_TYPE,</if>
<if test="CHANGE_LENGTH != null and CHANGE_LENGTH != '' ">CHANGE_LENGTH,</if>
<if test="SELF_WEIGHT != null and SELF_WEIGHT != '' ">SELF_WEIGHT,</if>
<if test="LOAD != null and LOAD != '' ">LOAD,</if>
<if test="REMARK != null and REMARK != '' ">REMARK,</if>
<if test="CREATED != null and CREATED != '' ">CREATED,</if>
<if test="CREATOR != null and CREATOR != '' ">CREATOR,</if>
<if test="CHANGED != null and CHANGED != '' ">CHANGED,</if>
<if test="CHANGER != null and CHANGER != '' ">CHANGER,</if>
<if test="IS_DELETED != null and IS_DELETED != '' ">IS_DELETED</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">sys_guid(),
<if test="1 == 1">#{WAGON_NUMBER},</if>
<if test="WAGON_TYPE != null and WAGON_TYPE != '' ">#{WAGON_TYPE},</if>
<if test="CHANGE_LENGTH != null and CHANGE_LENGTH != '' ">#{CHANGE_LENGTH},</if>
<if test="SELF_WEIGHT != null and SELF_WEIGHT != '' ">#{SELF_WEIGHT},</if>
<if test="LOAD != null and LOAD != '' ">#{LOAD},</if>
<if test="REMARK != null and REMARK != '' ">#{REMARK},</if>
<if test="CREATED != null and CREATED != '' ">#{CREATED},</if>
<if test="CREATOR != null and CREATOR != '' ">#{CREATOR},</if>
<if test="CHANGED != null and CHANGED != '' ">#{CHANGED},</if>
<if test="CHANGER != null and CHANGER != '' ">#{CHANGER},</if>
<if test="IS_DELETED != null and IS_DELETED != '' ">#{IS_DELETED}</if>
</trim>
Oracle一条数据多表连插的更多相关文章
- jdbc如何锁定某一条数据或者表,不让别人操作?
jdbc如何锁定某一条数据或者表,不让别人操作? 只有并发的时候才会有死锁,你要把多个涉及到这个表的地方检查一下,排除死锁可能. 为了避免修改冲突,所以我要锁定.请问该如何实现 答: 例如:selec ...
- 十几万条数据的表中,基于帝国cms 。自己亲身体验三种批量更新数据的方法,每一种的速度是什么样的
需求是 上传Excel 读取里面的数据.根据Excel中某一个字段,与数据表中的一个字段的唯一性.然后把 Excel表中数据和数据库表中数据一次更改.本次测试一次更新31条数据. 本次测试基于帝国cm ...
- 解决 Oracle exp导出表数据时空表不能导出的问题
一.不能导出空表的原因 1.Oracle11g默认对空表不分配segment,故使用exp导出Oracle11g数据库时,空表不会导出. 2.设置deferred_segment_creation 参 ...
- 使用SqlBulkCopy批量插入多条数据进入表中
由于工作中项目需求结算一次生成一批相同批次号的数据插入一个表中,然后再通过另一页面展示出来,所以需要用到一次性插入一批数据,所以就采用了SqlBulkCopy插入一批数据 1 public stati ...
- mysql生成20万条数据(连表插入)
创建一个存储过程 DELIMITER $$ -- 设置定界符为$$,与';'意思相同,防止相同符号产生冲突 USE `yunkc_base1`$$ -- 使用数据库 DROP PROCEDURE IF ...
- 给mysql一百万条数据的表添加索引
直接alter table add index 添加索引,执行一个小时没反应,并且会导致锁表:故放弃该办法,最终解决办法如下: 一.打开mysql 命令行客户端 这里我们那可以看到导出的数据文件所存放 ...
- Python开发【笔记】:pymsyql 插入一条数据同时获取新插数据的自增id的两种方式
一.通过cursor.lastrowid import pymysql.cursors # Connect to the database connection = pymysql.connect(h ...
- ORACLE中 大量数据插入表 SQL
declare g_commit_count number; cursor cu1 is select gl_flexfields_pkg.get_description_sql(gcc.chart_ ...
- Oracle 多条数据转一行逗号隔开
wm_concat 例: select wm_concat(市) from pa50 where apa132=省
随机推荐
- JVM配置参数理解,Cannot load this JVM TI agent twice
基本参数 -Xms128m JVM初始分配的堆内存 -Xmx512m JVM最大允许分配的堆内存,按需分配 -XX:PermSize=64M JVM初始分配的非堆内存 -XX:MaxPermSize= ...
- 尝试让Virtualbox的Ubuntu可以调整分辨率
在Virtualbox安装的Ubuntu,默认不是全屏,操作起来不是很方便,网上查了资料,按照网上的教程来操作并记录下自己的操作记录. 在安装的Ubuntu的虚拟机,通过 "设备" ...
- mysql服务命令行操作
启动 net start mysql 关闭 net stop mysql 登陆 mysql -hlocalhost -uusername -ppassword 退出 exit 显示数据库 show d ...
- DELPHI中如何闪烁应用程序窗口或任务栏按钮
使用FlashWindowEx函数: 一.设置FlashWInfoDelphi中TFlashWInfo申明如下:TypeTFlashWInfo = record cbSize : LongInt; h ...
- flume配置参数的意义
1.监控端口数据: flume启动: [bingo@hadoop102 flume]$ bin/flume-ng agent --conf conf/ --name a1 --conf-file jo ...
- NX二次开发-隐藏对象UF_OBJ_set_blank_status
NX9+VS2012 #include <uf.h> #include <uf_curve.h> #include <uf_obj.h> UF_initialize ...
- NX二次开发-UFUN特征找体UF_MODL_ask_feat_body
NX11+VS2013 #include <uf.h> #include <uf_modl.h> UF_initialize(); //创建块 UF_FEATURE_SIGN ...
- Python中将dict转换为kwargs
Python中将dict转换为kwargs 我们都知道kwargs是变长kv参数,能否将dict转换成kwargs. 在python调用函数的时候func(**{'type'='event'}),可以 ...
- EnhanceFunc__增强函数集
想将经常用到的功能函数写在一起,花时间精心维护,然后以后就用起来就舒服很多了 目前就写了进程调试权限,远程线程注入,远程线程释放这三个函数.还有很多功能,以后慢慢加 // last code by g ...
- 关于double的输入输出
double定义的变量输入的时候一定要%lf输入,要是%f输入的话,得到的结果会是0 float输入的时候是%f 但是在输出的时候%lf和%f都可以输出 建议使用double类型时,用%lf输入,%f ...