View previous topic :: View next topic
|
Author |
Message |
chaoj
Active User
Joined: 03 Jun 2010 Posts: 103 Location: Dalian
|
|
|
|
when I want to sort the member by changed date I use SORT CHA command
now I want to sort the member with order I specify
I want to know how SORT CHA command works
can anyone tell me what is the command type of SORT , or tell me which reference I should read ? |
|
Back to top |
|
|
Dsingh29
Active User
Joined: 16 Dec 2008 Posts: 132 Location: IBM
|
|
|
|
Can you please elaborate on
"now I want to sort the member with order I specify" |
|
Back to top |
|
|
chaoj
Active User
Joined: 03 Jun 2010 Posts: 103 Location: Dalian
|
|
|
|
Dsingh29 wrote: |
Can you please elaborate on
"now I want to sort the member with order I specify" |
For example I want to sort the members by the order I stored in a stem
(I'll get the compile date of the load module , then sort by that date , SORT CHA not work for load module LIB) |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
chaoj wrote: |
Dsingh29 wrote: |
Can you please elaborate on
"now I want to sort the member with order I specify" |
For example I want to sort the members by the order I stored in a stem
(I'll get the compile date of the load module , then sort by that date , SORT CHA not work for load module LIB) |
What do you mean by the "compile date" of a load module? A load module can contain many programs of various types. Or do you mean the link/bind date of the load module?
I'm not sure that that particular SORT is going to be any use to you, it is fairly specific and operating off the library stats, I believe. If they are not in the directory, they are not in the directory. |
|
Back to top |
|
|
Dsingh29
Active User
Joined: 16 Dec 2008 Posts: 132 Location: IBM
|
|
|
|
Chaoj,
I can deduce that, you want to see if your loadlib has the latest load module or not. For that you can look inside the load module, and look for current year or date, and you could be sure that this is the latest load module.
If you trying to achieve different, please explain, others might suggest better solutions. |
|
Back to top |
|
|
chaoj
Active User
Joined: 03 Jun 2010 Posts: 103 Location: Dalian
|
|
|
|
Dsingh29 wrote: |
Chaoj,
I can deduce that, you want to see if your loadlib has the latest load module or not. For that you can look inside the load module, and look for current year or date, and you could be sure that this is the latest load module.
If you trying to achieve different, please explain, others might suggest better solutions. |
I know how to check the date of the load module , I just want to use REXX to sort that date like SORT CHA , cause I don't know how SORT works, I can not write the REXX , I want to know how SORT command work , then I can refer it to write the REXX |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1744 Location: Tirupur, India
|
|
|
|
I think what you are trying to achieve might not be related to SORT CHA ISPF command.
Quote: |
I want to know how SORT command work , then I can refer it to write the REXX |
I guess the SORT ISPF command fetches the information from PDS' "directory" which has the ISPF statistics and displays members based on the CHAnged date.
PDS directory has the ISPF creation date, changed date and other statistics, the directory will look something like,
Code: |
----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8
----+----F----+----F----+----F----+----F----+----F----+----F----+----F----+----F
----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8
------------------------------------------------------------------------------
********************************* Top of Data **********************************
------------------------------------------------------------------------------
.ÚMEMBER1 .......ç...|...|........USERID1 MEMBER2 ...........|...|........USER
0FDCDCCDF4001000040114011402010000EECDCCF444DCDCCDF4002000010114011403000000EECD
0E4542591002DF1108119F119F77060000425994100045425920021F1001119F119F700C0C004259
------------------------------------------------------------------------------
ID1 MEMBER3 .......á...?...?........USERID1 MEMBER4 ........................
CCF444DCDCCDF4001000040126012602010100EECDCCF444DCDCCDF4000000020112011200010100
9410004542593003EF1105111F111F460A080042599410004542594001EF1004115F115F35000000
------------------------------------------------------------------------------
USERID1 MEMBER5 ........................USERID1 MEMBER6 ....................
EECDCCF444DCDCCDF4001000010112011201000100EECDCCF444DCDCCDF400100000011201120101
425994100045425950027F1209119F119F560C0800425994100045425960011F1107115F115F420B |
When a PDS is read with RECFM=U(works with IEBGENER not with PGM=SORT) and then written 'as is' into a output dataset you can see the directory information. |
|
Back to top |
|
|
chaoj
Active User
Joined: 03 Jun 2010 Posts: 103 Location: Dalian
|
|
|
|
vasanthz wrote: |
I think what you are trying to achieve might not be related to SORT CHA ISPF command.
Quote: |
I want to know how SORT command work , then I can refer it to write the REXX |
I guess the SORT ISPF command fetches the information from PDS' "directory" which has the ISPF statistics and displays members based on the CHAnged date.
PDS directory has the ISPF creation date, changed date and other statistics, the directory will look something like,
Code: |
----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8
----+----F----+----F----+----F----+----F----+----F----+----F----+----F----+----F
----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8
------------------------------------------------------------------------------
********************************* Top of Data **********************************
------------------------------------------------------------------------------
.ÚMEMBER1 .......ç...|...|........USERID1 MEMBER2 ...........|...|........USER
0FDCDCCDF4001000040114011402010000EECDCCF444DCDCCDF4002000010114011403000000EECD
0E4542591002DF1108119F119F77060000425994100045425920021F1001119F119F700C0C004259
------------------------------------------------------------------------------
ID1 MEMBER3 .......á...?...?........USERID1 MEMBER4 ........................
CCF444DCDCCDF4001000040126012602010100EECDCCF444DCDCCDF4000000020112011200010100
9410004542593003EF1105111F111F460A080042599410004542594001EF1004115F115F35000000
------------------------------------------------------------------------------
USERID1 MEMBER5 ........................USERID1 MEMBER6 ....................
EECDCCF444DCDCCDF4001000010112011201000100EECDCCF444DCDCCDF400100000011201120101
425994100045425950027F1209119F119F560C0800425994100045425960011F1107115F115F420B |
When a PDS is read with RECFM=U(works with IEBGENER not with PGM=SORT) and then written 'as is' into a output dataset you can see the directory information. |
Thanks vasanthz.
If ISPF command : SORT get status from PDS directory , do you know
how redisplay the sorted members ? |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1744 Location: Tirupur, India
|
|
|
|
Quote: |
how redisplay the sorted members ? |
So you already have member names and the corresponding link/bind dates using a program and now you are trying to redisplay the screen based on bind/link dates right?
No I am not aware of how to do it |
|
Back to top |
|
|
chaoj
Active User
Joined: 03 Jun 2010 Posts: 103 Location: Dalian
|
|
|
|
vasanthz wrote: |
Quote: |
how redisplay the sorted members ? |
So you already have member names and the corresponding link/bind dates using a program and now you are trying to redisplay the screen based on bind/link dates right?
No I am not aware of how to do it |
yes you're right |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2593 Location: Silicon Valley
|
|
|
|
SORT is an internal command that is processed by the member list display. It is an internal command and does not have a programming interface. I do not think you can do what you want with ISPF's member list display.
But, you should be able to:
1. capture the member information,
2. use TBCREATE to create a new table
3. use TBADD to add your member information in the order you want
4. use TBDISPL to show the information. |
|
Back to top |
|
|
don.leahy
Active Member
Joined: 06 Jul 2010 Posts: 765 Location: Whitby, ON, Canada
|
|
|
|
One way is to capture the member name and its bind/link date in your own ISPF table, and then display (via TBDISPL) that in lieu of a real member list. |
|
Back to top |
|
|
chaoj
Active User
Joined: 03 Jun 2010 Posts: 103 Location: Dalian
|
|
|
|
Pedro wrote: |
SORT is an internal command that is processed by the member list display. It is an internal command and does not have a programming interface. I do not think you can do what you want with ISPF's member list display.
But, you should be able to:
1. capture the member information,
2. use TBCREATE to create a new table
3. use TBADD to add your member information in the order you want
4. use TBDISPL to show the information. |
Thank you Pedro ! I'll learn to use table . |
|
Back to top |
|
|
chaoj
Active User
Joined: 03 Jun 2010 Posts: 103 Location: Dalian
|
|
|
|
don.leahy wrote: |
One way is to capture the member name and its bind/link date in your own ISPF table, and then display (via TBDISPL) that in lieu of a real member list. |
Thank you don.leahy ! I'll learn to use table . |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10886 Location: italy
|
|
|
|
Quote: |
can anyone tell me what is the command type of SORT , or tell me which reference I should read ? |
did it occur to You that the info You ask for is available in the ISPF manuals
( link posted zillions of times on this forum )
or by scrolling thru the ISPF tutorial ( PF1 and friends ) ???
since the ISPF SORT command can sort on any column of the member list display
I really do not see any reason to write Your own.
if the member does not have the ISPF statistics the only sort is on the name!
and the member without stats will apper at the top or at the bottom of any sorted list
( apart obviously the name sorted one ) |
|
Back to top |
|
|
|