Primary Commands in Edit or Browse or View modes
Primary Commands in Edit or Browse or View modes
Primary Commands are commands that can be entered on the command line while working with a dataset or member of a Partitioned Dataset (PDS). These commands allow you to perform various operations, such as searching, editing, sorting, or managing data.
General Rules -
- Separators: Use either a blank or a comma to separate command operands.
- Command Input Field:
- Trailing nulls exist, so you can insert/expand operands but cannot use cursor keys to add spaces between operands.
- Error Handling: If there’s an error in the command, a message is displayed, and the command remains in the command field.
- Ampersand Usage (&): Precede a command with & to keep it in the command field after execution.
Note! All the below commands are applicable when the dataset is opened in Edit or Browse or View modes
Primary Commands -
Command | Description | Usage/Example |
---|---|---|
BOUNDS | Set left and right margins for editing. | BOUNDS 1 72 sets boundaries to columns 1-72. |
CANCEL | Cancel editing without saving changes. | CANCEL exits without saving. |
CAPS | Set CAPS mode ON or OFF. | CAPS ON saves data in uppercase. |
CHANGE | Find and replace a string. | CHANGE ABC XYZ ALL replaces ABC with XYZ. |
COPY | Copy data from another member or dataset. | COPY MEMBER1 copies contents of MEMBER1. |
CREATE | Create a new member in a PDS. | CREATE NEWMEM creates a member NEWMEM. |
CUT | Copy or move data to a clipboard. | CUT saves the selected lines. |
DISPLAY | Show invalid characters in Browse mode. | DISPLAY makes non-printable characters visible. |
DELETE | Delete lines in edit mode. | DELETE ALL removes all excluded lines. |
EDIT | Open another member for editing recursively. | EDIT MEMBER2 opens MEMBER2 for editing. |
END | Exit the edit session. Saves changes based on the AutoSave setting. | END ends the session. |
EXCLUDE | Hide lines containing a specific string. | EXCLUDE ABC hides lines with ABC. |
FIND | Locate a specific character string. | FIND XYZ locates XYZ in the dataset. |
HEX | Enable HEX mode to view hex values. | HEX ON turns on hex display. |
HILITE | Enable enhanced color settings for code. | HILITE COBOL highlights COBOL syntax. |
MODEL | Insert predefined templates or models. | MODEL JCL copies a predefined JCL template. |
MOVE | Move data to another member or dataset. | MOVE MEMBER3 moves contents to MEMBER3. |
NULLS | Turn NULLS mode on or off. | NULLS ON enables null fields. |
NUMBER | Enable line numbering. | NUMBER adds sequence numbers. |
PASTE | Paste data copied with the CUT command. | PASTE pastes the clipboard content. |
RENUM | Renumber lines in NUMBER mode. | RENUM renumbers all lines sequentially. |
REPLACE | Replace a member or dataset. | REPLACE MEMBER4 replaces MEMBER4 content. |
SAVE | Save changes without exiting the editor. | SAVE writes changes to the dataset. |
SORT | Sort data based on columns or sequence. | SORT 1 10 A sorts columns 1-10 in ascending order. |
TABS | Enable/disable TABS mode and set logical tabs. | TABS ON turns on tabs. |
UNDO | Undo the last change or command. | UNDO reverts the last action. |
UNNUM | Remove line numbering. | UNNUM clears sequence numbers. |
Examples -
In the EDIT screen, standard scrolling commands like UP, DOWN, LEFT, and RIGHT are valid. For example:
- DOWN 5: Moves the display down by 5 lines.
- UP 10: Moves the display up by 10 lines.
- CREATE SIXTENPG: Creates new member.