db2 import和load
LOAD,BUILD,DELETE 三个阶段对硬盘上的数据页面来进行直接的处理。Load工具类似Oracle sql*loader工具的直接路径导入。
SQL authorization ID = HUATENG
Local database alias = DBTEST
db2 (cont.) => no cascade
db2 (cont.) => before insert on test
db2 (cont.) => referencing new as n
db2 (cont.) => for each row
db2 (cont.) => begin atomic
db2 (cont.) => set n.name=n.name||' [import test]';
db2 (cont.) => end @
----------- --------------------
1 a [import test]
1,"aa"
2,"bb"
3,"cc"
4,"dd"
5,"ee"
6,"ff"
db2 => import from test.txt of del insert into test @
SQL3109N The utility is beginning to load data from file "test.txt".
primary key, unique constraint or unique index identified by "1" constrains table "HUATENG.TEST" from having duplicate values for the index key.
SQLSTATE=23505
Number of rows skipped = 0
Number of rows inserted = 5
Number of rows updated = 0
Number of rows rejected = 1
Number of rows committed = 6
----------- --------------------
1 a [import test]
2 bb [import test]
3 cc [import test]
4 dd [import test]
5 ee [import test]
6 ff [import test]
其他导入的记录也都触发了触发器操作。
----------- --------------------
1 a [import test]
db2 (cont.) => @
1,"aa"
2,"bb"
3,"cc"
4,"dd"
5,"ee"
6,"ff"
db2 => load from test.txt of del insert into test @
SQL3501W The table space(s) in which the table resides will not be placed in backup pending state since forward recovery is disabled for the database.
Number of rows skipped = 0
Number of rows loaded = 6
Number of rows rejected = 0
Number of rows deleted = 1
Number of rows committed = 6
----------- --------------------
1 a [import test]
2 bb
3 cc
4 dd
5 ee
6 ff
db2 import和load的更多相关文章
- db2 import export load
DB2中所谓的数据移动,包括: 1. 数据的导入(Import) 2. 数据的导出(Export) 3. 数据的装入(Load) 导入和装入都是利用DB2的相关命令把某种格式的文件中的数据保存到数据库 ...
- win7 32位 安装opencv-python后,运行时提示 "from .cv2 import *: DLL load failed: 找不到指定的模块" 的解决办法
安装opencv后,运行一个测试程序提示"from .cv2 import *: DLL load failed: 找不到指定的模块".于是百度一下解决办法,结果试了N多方法后也没 ...
- DB2 Z/os Load utility 使用
Use the LOAD online utility to load one or more tables of a table space. The LOAD utility loads reco ...
- 【DB2】文件导入导出常见命令总结 EXPORT IMPORT LOAD
参考文献地址:https://blog.csdn.net/reaper1022/article/details/18601973 Db2 的数据迁移,最常用的就是导入导出功能,而导入导出的命令貌似简单 ...
- db2 load选项
db2 load使用 最近有个好朋友因为load问题导致了生产故障,所以特意写篇文章总结一下load的用法及注意事项. 1.load概述 数据的导入方法有insert,import和load三种,其中 ...
- 【DB2】db2命令Export与Import
环境准备 1.新建表 qinys@Linux:~> db2 "create table tb1(id int,dt timestamp,name varchar(100))" ...
- [转]DB2 load参数
本文持续更新,LOAD如何提高parallelism.LOAD SHRLEVEL CHANGE的性能提高. =========================== Every once in a wh ...
- db2基础
DB2知识文档 一.db2 基础 基本语法 注释:"--"(两个减号) 字符串连接:"||" 如set msg='aaaa'||'bbbb',则msg为'aaa ...
- DB2 常用命令小结
. 打开命令行窗口 #db2cmd . 打开控制中心 # db2cmd db2cc . 打开命令编辑器 db2cmd db2ce =====操作数据库命令===== . 启动数据库实例 #db2sta ...
随机推荐
- js 多级联动(省、市、区)
js 多级联动(省.市.区) CreateTime--2018年4月9日17:10:38 Author:Marydon 方式一: 数据从数据库获取,ajax实现局部刷新 方式二: 数据从json文 ...
- 通用的sql语句
1.插入: INSERT INTO 表名称 VALUES (值1, 值2,....) 我们也可以指定所要插入数据的列: INSERT INTO table_name (列1, 列2,...) VALU ...
- ubuntu截图工具
ubuntu截图工具 首先,我们用apt-get install 去安装一个,scrot 主要用在命令行下,它使用 imlib2 库来抓取并保存图像 sudo a ...
- OpenSAML2.X 在SSO系统中的应用
背景 年底的时候有机会开发一个SPA(单页面应用)的项目,那时候须要用到票据的方式能够用Cookie的方式来登录.当是想到了OpenID或者是CAS的方式来做统一认证中心.后来一个安全界的大牛推荐让我 ...
- CTC loss 理解
参考文献 CTC学习笔记(一) 简介:https://blog.csdn.net/xmdxcsj/article/details/51763868 CTC学习笔记(二) 训练和公式推导 很详细的公示推 ...
- 百度MIP(百度版的google AMP)了解一下?
官网:https://www.mipengine.org/ 视频教学:http://bit.baidu.com/subject/datalist/sid/10/cid/22.html github:h ...
- HttpPutFormContentFilter 和 ContextLoaderListener 讲解
1 ContextLoaderListener 继承自ContextLoader,并且实现ServletContextListener接口. 肯定得实现这个接口了,不然怎么作为Servlet的监听器呢 ...
- Atitit.基于时间戳的农历日历历法日期计算
Atitit.基于时间戳的农历日历历法日期计算 1. 农历xx年的大小月份根据万年历查询1 2. 农历xx年1月1日的时间戳获取1 3. 计算当年的时间戳与农历日期的对应表,时间戳为key,日期为va ...
- SignalTap ii的使用
1.实现原理 SignalTap II获取实时数据的原理是在工程中引入Megafunction中的ELA(Embedded Logic Analyzer),以预先设定的时钟采样实时数据,并存储于FPG ...
- [svc]influxdb最佳实战-监控对比
最近在搞容器的监控,遇到influxdb这个库,搞了两天,些许明白了些套路,做个记录,备忘.... 小结如下: influxdb go语言编写 默认情况influxdb创建的库关联autogen的RP ...