15 pts.
 Reading an unknown file in RPG
Hi All, I am working on a DBU like utility which will provide a maintainance screen for each file. I need to read the file in an rpg program but i dont know the program name till runtime. I can't declare the file in F specs as i dont know the file name. SQL is very bothering and is very heavy for the interactive application. Plese suggest some other way to do this. Thanks in advance

Software/Hardware used:
ASKED: March 19, 2009  12:27 PM
UPDATED: March 19, 2009  2:38 PM

Answer Wiki:
Hi, You could declare the file as internally defined with user open, then you can do an OVRDBF to the correct file at run time and open the file. Regards, Martin Gilbert. /////////////////////////// Why? You're taking on quite a chore, that has good comercial solutions. You could declare your file as Internally described .. but then you have no field definitions. You can capture the field definitions in a number of ways (DSPFFD or in SQL). You've got a lot of work ahead of you. Phil ///////////////////////// Hi, You could also retrieve the field descriptions and details on the file description from the cross reference tables. Regards, Martin Gilbert. /////////////////////////////////////////////////////////////////////// You're right - as always, Martin. And it's still quite a chore. Are there some freebee or cheepe that does this? -- Oh there's always DFU. Phil
Last Wiki Answer Submitted:  March 19, 2009  2:38 pm  by  Gilly400   23,625 pts.
All Answer Wiki Contributors:  Gilly400   23,625 pts. , philpl1jb   44,190 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _