db2常用操作

1. db2建立远程节点编目及删除

db2 catalog tcpip node nodeName remote remoteIp server remotePort

db2 list node directory

eg. db2 catalog tcpip node TESTND remote 123.123.123.123 server 60008

db2 uncatalog node TESTND

2. db2建立数据库编目及删除

db2 catalog db dbName as dbAlisName at node nodeName

db2 list db directory

e.g db2 catalog db TESTDB as  TESTDB at node TESTND

db2 uncatalog db TESTDB

3. db2导出数据

db2 "connect to test_db user test_user using test_pwd"
db2 "export to test.ixf of ixf select * from test_schema.test_table"
db2 terminate

4. db2导入数据

db2 "import from test.ixf of ixf insert_update into  test_schema.test_table"

原文地址:https://www.cnblogs.com/darange/p/9368010.html