|
In the archives of the midrange-rpg list has been posted the rpgle code to read an ifs directory, returning the list of files and their attributes. Easy to customize for what you want. Original post was well over year ago. I copied it and built a program to constantly monitor a directory for new entries to process. Sorry but customer says I cannot share the code. jim ----- Original Message ----- From: "Andre Manriquez" <amanriquez@xxxxxxxxxxxxxxxxxxx> To: <midrange-l@xxxxxxxxxxxx> Sent: Thursday, August 14, 2003 10:26 PM Subject: Automating Copy Stream Files > I have a situation where a PC is tranferring files via FTP to the iSeries (AS/400) FTP Server and placing the files into an IFS directory. Using the CPYFRMSTMF cmd I can get those files into a DB2/400 - file/lib/mbr. The only problem is that the CPYFRMSTMF cmd is done on a one file basis. In other words if I place 10 files in the IFS directory I have to do the CPYFRMSTMF command 10 times for each file and I have to be exact for each file name...file names can/will differ. > > BTW, my PC based FTP client does not offer the capability to use Site commands so I cannot use "Quote site na0" naming format to go directly to the DB2/400 side. It automatically defaults to na1. > > So my questions are: > > 1. Is there a way to tell the AS/400 copy all files, *all perhaps, within a given directory to a file/lib/mbr?...perhaps to a lib only instead of to a specific file and create the files dynamically based on names in the IFS? > > 2. Thru a CL program is there a way to do something like read out all file names within a directory and call the CPYFRMSTMF cmd for each file name?? > > I'm looking to automate these steps thru a CL and OS/400 scheduler. Any thoughts or insight would be greatly appreciated. > > Please feel free to contact me directly offline if you wish. Thank you. > > AM > > 925-743-0283 O > 510-406-3575 C > > _______________________________________________ > This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list > To post a message email: MIDRANGE-L@xxxxxxxxxxxx > To subscribe, unsubscribe, or change list options, > visit: http://lists.midrange.com/mailman/listinfo/midrange-l > or email: MIDRANGE-L-request@xxxxxxxxxxxx > Before posting, please take a moment to review the archives > at http://archive.midrange.com/midrange-l. > >
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.