Read it like you would any other file.
You will need to do a OVRDBF to get the correct member.
Your source file will have 3 fields: SRCSEQ, SRCDAT, and SRCDTA.
The SRCDTA will have your COBOL statements
Promodhhs,
You could also use File Transfer to copy your source statements to a .txt file.
Hope this helps,
Bill Poulin
Promodhss,
File or Data Transfer is part of iSeries Access for Windows.
To Activate Wizard, Right click on your desktop,
Select New,
Select Data Transfer from iSeries Server,
Wizard should appear, Select Next,
Identify your iSeries Server Name, Select Next,
Identify the Library/File(Member) name, Select Next,
Identify Device, File, Select Next,
Identify File Name, (I usually use Browse), Select Next,
Here you can customize formating etc, just Select Next,
Select Finish. Transfer has been created.
To run Select Transfer data from iSeries,
Confirmation message should appear.
Hope this helps,
Bill Poulin
Hi Bill Poulin,
Thanks for ur rly but i am not familiar in this. So can u plz give some examples.
You can create a flat file with 80 char length (FILEA). Create a program (COBOL or RPG) reading a database file (QCBLSRC) and writing to FILEA (record length 80) from field “SRCDTA”. Create a CL program with OVRDBF for QCBLSRC using yourlib/QCBLSRC mbrname, then call your program (COBOL or RPG), and DLTOVR QCBLSRC. The yourlib and mbrname can be a parm passed or hardcoded (for oneshot program).
I tried “CPYF FROMFILE(mylib/QCBLSRC) TOFILE(TRASH/SRCDTA) FROMMBR(CRTFLATFL) MBROPT(*ADD) FMTOPT(*cvtsrc)”, where “TRASH/SRCDTA” was created using “CRTPF FILE(TRASH/SRCDTA) RCDLEN(80)”. It looked like it copied correctly.