You Can View User Feedback To This Tip
Follow the directions below to verify the existence of a PTF on your system. In doing this, you'll eliminate the need of having to know the product code to find the PTF.
1. Run the DSPPTF command, placing the output into a file.
2. Run RTVPFSRC command to get source member for the file just created.
3. Copy the physical file source, creating a new source member that you change the type to logical file.
4. Edit the Logical file source and point toward the physical file created earlier. Remove all fields not needed for your display purposes. Define the key as the PTF name only. Create the logical file.
5. Create a DFU over the logical file. Select all fields. Edit the fields and set all of them to display only except the PTF ID field. Create the DFU.
6. Create a CLP program to drive the DFU: Label . . . . . . . . . . . . . Option: DFU option . . . . . . . . . . > 1 1-5, *SELECT Run option . . . . . . . . . . > 2 1-2, *NONE DFU program . . . . . . . . . . > PTFFIND Name, *PRV Library . . . . . . . . . . . > COMMON Name, *PRV, *LIBL, *CURLIB Data base file . . . . . . . . . > PTFFILEL1 Name, *PRV, *SAME Library . . . . . . . . . . . > COMMON Name, *PRV, *LIBL, *CURLIB Member . . . . . . . . . . . . . > *FIRST Name, *PRV, *FIRST Comment . . . . . . . . . . . .
7. Create a command to invoke the CLP and your set to go.
Note: Once the PTF is displayed, you can roll up and down through the file to view other PTFs. This is handy when upgrading and checking cross-reference listings.
Any questions, send me an e-mail. I can give you a phone number at that time if necessary.
- A simpler way of finding whether or not a PTF exists on your machine is to run the command DSPPTF OUTPUT(*PRINT), display the resulting report and then use F16 to scan for the relavant PTF. This is also useful for checking if all PTFs have been applied after a CUM installation - scan for "ot applied" - leaving out the leading "N" or "n" ensures that you don't miss a match due to getting he case wrong. Peter Shearer
================================== MORE INFORMATION ON THIS TOPIC ==================================
The Best Web Links: tips, tutorials and more.
Ask your programming questions--or help out your peers by answering them--in our live discussion forums.
Ask the Experts yourself: Our application development gurus are waiting to answer your programming questions.
This was first published in September 2003