I have been struggling to find a way to check whether a PTF
is applied on my IBM i machine or not since I have to code an RPG program to first check if the PTF
is applied on IBM i machine then only execute some set of IBM i commands.
Sorry, you do not have permission to ask a question, You must login to ask a question.
Sorry, you do not have permission to ask a question.
You can check if a
PTF
is applied on an IBM i machine. There are various ways to check it.GO PTF
command that you can use to work with the PTF-related things. You need to type it on the command line and press Enter. You can check for specific PTF usingoption 5
display Program temporary fixes (PTF) information. Option 5 triggers theDSPPTF
command and displays the command screen where you have to provide more details to be able to find information about the PTF.PTF number
available with you then you can use this SQL query to check if PTF is applied on your IBM i machine or not.If the above query does not return any row then that means
PTF is not applied
. If it returns a row then we need to check for loaded status if the loaded status isPERMANENTLY APPLIED
thenPTF is applied
on your IBM i machine and if the loaded status isSUPERSEDED
then as per the IBM page that meansA later PTF existed on the system, but it may not be applied. If this PTF has been superseded, display the PTF details to determine the PTF number that supersedes this PTF, and then display the PTF to determine its status.
You can get the latest superseding PTF details by also selecting the columnPTF_SUPERSEDED_BY_PTF
fromQSYS2/PTF_INFO
and then you need to checkLoaded Status
of PTF for this superseding PTF to confirm if the PTF is applied on your IBM i machine.QPZRTVFX
to retrieve the PTF information. However, this api returnsPTF loaded status
in the form of numbers ranging from0 to 6
instead to text because statuses are translatable text instead of special values.0
: the PTF has never been loaded.1
: the PTF has been loaded.2
: the PTF has been applied.3
: the PTF has been applied permanently.4
: the PTF has been permanently removed.5
: the PTF is damaged. An error occurred while applying the PTF. It needs to be reloaded and applied.6
: the PTF is superseded, meaning another PTF with more recent changes has been loaded on the system. Theptf id
that has been loaded can be found in the superseded byptf id
field.