70 pts.
 Finiding the PF name
Hi Guys,

I am stuck in here to find the physical file name, I know the alternate name of the PF, is there any procedure to find out the original PF name using the alternate name?

Please help



Software/Hardware used:
AS400, DB2400
ASKED: July 9, 2010  9:38 AM
UPDATED: July 9, 2010  10:31 PM

Answer Wiki:
I suspect you're thinking the "alternate" name is a logical file? Use the DSPDBR command (display data base relationships) =================================================== If "alternate name" is a LF, then DSPDBR won't help. For a normal LF, use:<pre> DSPFD mylib/altname TYPE(*ACCPTH)</pre> ...where "altname" is the LF name and "mylib" is the library containing the LF. The name of the PF that is accessed by the LF will be at the end of the displayed information. However, if "alternate name" refers to a SQL ALIAS, then perhaps use:<pre> SELECT BASE_TABLE_NAME FROM SYSTABLES WHERE TABLE_NAME = '<altname>'</pre> ...where "<altname>" is the ALIAS. Or perhaps "alternate name" means something else? If so, please describe how the name is used. We can probably figure it out from there. Tom
Last Wiki Answer Submitted:  July 9, 2010  8:52 pm  by  AnchorS   380 pts.
All Answer Wiki Contributors:  AnchorS   380 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


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


 

select system_table_name, table_name from systables

Phil

 44,070 pts.