Easy program deployment using db2 federated database

Source: Internet
Author: User

Using the db2 federal database to easily implement program deployment our project is all developed in the test environment during the transformation of crm2.0. When the production system goes online, all programs, tables, and data need to be migrated. There are many migration solutions. Finally, we chose the federal database migration solution for data and table migration. The specific idea is to establish a connection to the test database on the target database, then use create table ddd like ddd to create a table interface, and finally load data with a cursor. Www.2cto.com -- create wrapper FEDB2 LIBRARY 'libdb2drda. a' OPTIONS (ADD DB2_FENCED 'n'); -- CREATE the federated server create server FE206 TYPE DB2/UDB version' 9. 7 'wrapper FEDB2 authorization odsdev password odsdev OPTIONS (add dbname 'cqtest1'); -- CREATE a USER ing create user mapping for odsdev server FE206 OPTIONS (ADD REMOTE_AUTHID 'ossdev ', REMOTE_PASSWORD '******'); www.2cto.com -- CREATE nickname CREATE NICKNA Me tbowner. NT_CUST FOR FE206.TBOWNER. CUST; -- create table tbowner. cust like tbowner. NT_CUST IN TBS_ODS_01 compress yes not logged initially; -- load data DECLARE CUR_XXX cursor for select * from tbowner. NT_CUST; load from CUR_XXX of cursor replace into tbowner. CUST; in shell encapsulation, you can become a migration tool. Author u9999

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.