0

------------------------------------ ----------- --------- ------------------------------------ -----------------------------
-------
PRODUCT KIT TYPE STATE MAINTENANCE REFERENCED BY
------------------------------------ ----------- --------- ------------------------------------ -----------------------------
-------
HP I64VMS ACUXE V6.40-11P09A Full LP Installed
HP I64VMS AVAIL_MAN_BASE V8.3-1H1 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS CDSA V2.3-306 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS CSWS V2.1-1 Full LP Installed HP I64VMS CSWS211_UPDATE V1.0
HP I64VMS CSWS_PHP V1.3 Full LP Installed HP I64VMS CSWS_PHP13_UPDATE V1.0
HP I64VMS DECNET_PLUS V8.3-1H1 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS DWMOTIF V1.6 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS DWMOTIF_SUPPORT V8.3-1H1 Full LP Installed HP I64VMS VMS V8.3-1H1
HP I64VMS KERBEROS V3.1-152 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS OPENVMS V8.3-1H1 Platform Installed
HP I64VMS SMH V2.0-17 Full LP Installed HP I64VMS SMHPAT V2.0-20
HP I64VMS SSL V1.3-284 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS TCPIP V5.6-9ECO2 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS TDC_RT V2.3-1 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS VMS V8.3-1H1 Oper System Installed HP I64VMS CDSA V2.3-306
HP I64VMS DECNET_PLUS V8.3-1H1
HP I64VMS DWMOTIF V1.6
HP I64VMS KERBEROS V3.1-152
HP I64VMS OPENVMS V8.3-1H1
HP I64VMS TCPIP V5.6-9ECO2
HP I64VMS WBEMCIM V2.61-A070728 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS WBEMPROVIDERS V1.5-31 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
------------------------------------ ----------- --------- ------------------------------------ -----------------------------
-------

Hi above is my output of one of my command I want to filter each column value seprately. Please help me I am bugging my head from last 5-6 hours.

2
Contributors
1
Reply
2
Views
7 Years
Discussion Span
Last Post by vegaseat
0

Take a looky at something like this ...

data = """\
------------------------------------ ----------- --------- ------------------------------------ -----------------------------
-------
PRODUCT KIT TYPE STATE MAINTENANCE REFERENCED BY
------------------------------------ ----------- --------- ------------------------------------ -----------------------------
-------
HP I64VMS ACUXE V6.40-11P09A Full LP Installed
HP I64VMS AVAIL_MAN_BASE V8.3-1H1 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS CDSA V2.3-306 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS CSWS V2.1-1 Full LP Installed HP I64VMS CSWS211_UPDATE V1.0
HP I64VMS CSWS_PHP V1.3 Full LP Installed HP I64VMS CSWS_PHP13_UPDATE V1.0
HP I64VMS DECNET_PLUS V8.3-1H1 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS DWMOTIF V1.6 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS DWMOTIF_SUPPORT V8.3-1H1 Full LP Installed HP I64VMS VMS V8.3-1H1
HP I64VMS KERBEROS V3.1-152 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS OPENVMS V8.3-1H1 Platform Installed
HP I64VMS SMH V2.0-17 Full LP Installed HP I64VMS SMHPAT V2.0-20
HP I64VMS SSL V1.3-284 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS TCPIP V5.6-9ECO2 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS TDC_RT V2.3-1 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS VMS V8.3-1H1 Oper System Installed HP I64VMS CDSA V2.3-306
HP I64VMS DECNET_PLUS V8.3-1H1
HP I64VMS DWMOTIF V1.6
HP I64VMS KERBEROS V3.1-152
HP I64VMS OPENVMS V8.3-1H1
HP I64VMS TCPIP V5.6-9ECO2
HP I64VMS WBEMCIM V2.61-A070728 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
HP I64VMS WBEMPROVIDERS V1.5-31 Full LP Installed HP I64VMS OPENVMS V8.3-1H1
------------------------------------ ----------- --------- ------------------------------------ -----------------------------
-------
"""

data_list = data.split('\n')

for line in data_list:
    if line.startswith('HP'):
        # split line string at the first three spaces
        print line.split(' ', 3)
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.