Update
What I have described here has been made redundant by the introduction of the SQL Table Function IFS_OBJECT_STATISTICS.
Click on this link to read about IFS_OBJECT_STATISTICS.
I needed to make a job that would display a list of files in an IFS directory, allow a user to select one, copy contents of the file in the IFS directory to a file in the IBM i, and process the data. Always hearing the mantra KISS, Keep It Simple Simon, in my mind I searched for alternatives.
The person who taught me this mantra always made last the 'S' interchangeable between 'Simon' and 'Stupid', which left me thinking if I was being stupid? She always refused to elaborate.
I could use the 'Display Object links' DSPLNK, command. Alas, the output from this either display or print. If I output to print I could then copy the spool file to a physical file, and… that is unnecessarily complicated for something that should be simple.