2,480 pts.
 Moving data between 2 iSeries Servers
We have a Production iSeries and a Development iSeries. We want to be able to select data from our Production System and Transfer it to a programmers library on our Development System. When we were on a single system we used SQL/Cobol. We have been successful getting to the database on each system through the use of the SQL Connect statement, but can only Connect to one database at a time. The problem is where to store the data as we change connections. Any thoughts ? Thank You, Bill

Software/Hardware used:
ASKED: December 18, 2007  7:13 PM
UPDATED: March 8, 2010  8:31 PM

Answer Wiki:
If the goal is to transfer data to the development system for testing purposes then an easy way is to save the necessary objects to a *SAVF, FTP the *SAVF to the development system, and restore the objects to the development libraries. This can be easily automated if you want periodic updates to the development system and is the process I use across my systems. This has the added benefit of isolating production data from development errors. There are many other ways to also accomplish this. Bruce Vining Bruce Vining Services Bruce, Thank You, already familiar with this process. We are using SQL/Cobol so we can select records based on key information from multiple files in order to create a test environment for our programmers. Our code goes something like INSERT INTO PGMRLIB/FILEA SELECT *FROM PRODLIB/FILEA WHERE IDKEY = 'Key#' Again things worked great when production and development were on one system, our issue is Connecting to 2 databases, 1 on each system. Thanks, Bill ============================================================ It's possible to connect easily to two different databases at the same time, but it requires a product to enable it. In order to retrieve rows from one database and write into another with SQL yourself without additional products, you will need to code your SQL/COBOL using SQL CLI. Tom
Last Wiki Answer Submitted:  March 7, 2010  11:12 am  by  wpoulin   2,480 pts.
All Answer Wiki Contributors:  wpoulin   2,480 pts. , bvining   6,055 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

I may be missing something but ;
If the 2 can “talk” to each other have you tried DDM(s) ?

 1,000 pts.

 

Bicmac46,
Thank You, Yes we have tried DDM. It works great if we are copying the whole file from 1 system to the other, such as using the CPYF command. But when we use SQL against a DDM defined file we get SQL7011 not a table, view or physical file.

Thanks,
Bill

 2,480 pts.

 

Have you explored the parameters of the CPYF command (using DDM) that allow you to select records? They won’t match SQL for functionality but they still may do the trick.

 1,410 pts.