Is there a way to have only the active sessions displayed in the menu?

Document ID : KB000052456
Last Modified Date : 14/02/2018
Show Technical Document Details

Description:

For better switching between active sessions I would like to have only the active sessions displayed on the menu.

I would also like to have a possibility of selecting the sessions like 'display only the TSO sessions' on the menu.

Solution:

There is no standard way to do this but it can be achieved with the TPX Command Exit in some way.

Please review the TPX Command Exit.

*  THIS SAMPLE EXIT IMPLEMENTS FOLLOWING FUNCTIONS IN POINT 4:        *
*                                                                     *
*  - CHANGE PF3 ENTERED FROM THE MENU INTO /F COMMAND                 *
*                                                                     *
*  - IMPLEMENTS 2 NEW COMMANDS FROM MENU:                             *
*                                                                     *
*    'SS' - SHOW SESSION ID                                           *
*    'SD' - SHOW SESSION DESCRIPTION                                  *
*                                                                     *
*  EXAMPLES:                                                          *
*                                                                     *
*    - 'SS/SD ACT' WILL DISPLAY ONLY ACTIVE SESSIONS                  *
*    - 'SS/SD ALL' WILL DISPLAY ALL SESSIONS                          *
*                                                                     *
*    - 'SS TPX*' WILL DISPLAY ALL SESSIONS WITH SESSION ID            *
*                STARTING WITH STRING TPX                             *
*    - 'SS *TSO*' WILL DISPLAY ALL SESSIONS THAT HAVE STRING 'TSO'    *
*                 IN THE SESSION ID                                   *
*    - 'SD *PAYROLL* WILL DISPLAY ALL SESSIONS THAT HAVE STRING       *
*                    'PAYROLL' IN THE SESSION DESCRIPTION             *
*    - 'SD %%%1*' WILL DISPLAY ALL SESSIONS THAT HAVE A '1' IN THE    *
*                 FORTH POSITION OF THE SESSION DESCRIPTION           *
*                                                                     *
*  THE EXIT ALSO ALLOWS YOU TO PREDEFINE PF-KEYS WITH COMMANDS.       *
*  THIS IS DONE IN THE PFKTAB TABLE.                                  *
*                                                                     *
*  PREDEFINED EXAMPLES IN TABLE ARE:                                  *
*                                                                     *
*  DC    X'F4',X'07',AL1(SS)                                          *
*  DC    CL8'SS TSO*'            .PF4 = SHOW SESSIONS TSO*            *
*  DC    X'F5',X'07',AL1(SS)                                          *
*  DC    CL8'SS IMS*'            .PF5 = SHOW SESSIONS IMS*            *
*  DC    X'F6',X'04',AL1(SS)                                          *
*  DC    CL8'SS *'               .PF6 = DISPLAY ALL                   *
*  DC    X'F9',X'08',AL1(SS+ACT)                                      *
*  DC    CL8'SS *,ACT'           .PF9 = DISPLAY ONLY ACTIVE           *
*                                                                     *
*  ATTENTION: REGARDLESS OF THE SESSION SELECTION TPX WILL ALWAYS     *
*             DISPLAY THE ACTIVE SESSIONS TOO.                        *
*                                                                     *
*  THE EXIT CAN BE MODIFIED TO CHANGE THE ABOVE AS DESIRED OR         *
*  ENHANCE FURTHER.                                                   *
File Attachments:
TEC509133.zip