Using IBM i? Need to create Excel, CSV, HTML, JSON, PDF, SPOOL reports? Learn more about the fastest and least expensive tool for the job: SQL iQuery.
Happy New Year, everyone! A co-worker of mine asked me if I new of a way to extract the file names within an IFS folder to a database file. Off the top of my head I couldn't think of anything except the old dump contents to a printout, copy the printout to a flat file, parse out the data, etc, etc....
I hoping someone here may have found a slick way to handle this. I'm sure he'd appreciate any input!!
Thanks! Chris
RTVDIRINF ? Or there are API's you can call from RPG to open a directory and read the list of files. I can post those if you need them.
Chris R
We use a UDTF called IFSDIR and it works great! Once you get the function created you can use it right from your programs to populate a PF with a list of files that exist in an IFS folder. For example, I have one RPG program that displays a subfile list of certain jpg images found in a specific folder. We've found IFSDIR to be very useful and easy to use.
It's described here:
http://www2.systeminetwork.com/artarchive/index.cfm?fuseaction=viewarticle&CO_ContentID=17851
(for some reason, the page can sometimes take a while to come up)