Programming / RPG
My problem with that is that the file was generated by Synon, and the field names don't give you any clue as to what's actually held in the field. So that meant using DSPFFD to get the list of the fields and their descriptions. After a load of searching, I thought I had found the logical I was looking for. But when I used DSPFD again, I found that it had some select/omit statements that excluded some of the records that I needed. This was getting to be a real pain!
I started thinking about a better way of spending my time. Enter the QDBRTVFD API. This retrieves all of the info you could ever need about database files, plus a bit more. After some trial and a lot of errors, I managed to create my own DSPREL command. It shows all of the related logicals in a subfile. Listed beneath each file are the fields that make up the key, complete with their text description, so that you can easily see what the field holds. It also shows whether there are any select/omit rules. It lets you enter a selection beside any of the files that shows those rules, shows a complete list of all of the fields, allows you to query the file (in a better way than WRKQRY or RUNQRY), and a few other things as well. It also has an F16=Search function that lets you search for any text string in the file name, key field, or field text. It's handy if you are looking through a list of 20 logicals for something using the customer number. Just hit F16 and type "customer," and it will show you all of the hits.