2

how can we move the data in middle of PS file to left side in Mainframe? any shortcut command for this?

I have a Data set with data at column 13 and it has to be moved to column 11, Any short key to move it.

Want to align rest of the rows in DS as 1st row

 BROWSE    OSMDEV.ITALY3.DATA                 
 Command ===>                                 
----+----1----+----2----+----3----+----4----+-

758         200510  4323T                     
758           2005  10  4323N                 
758           2005  10  51149                 
758           2005  10  51154                 
758           2005  10  6758E                 
758           2005  13  34437                 
758           2005  13  34441                 
758           2005  13  53445
Turophile
  • 3,157
  • 1
  • 10
  • 21
Sandhya L
  • 21
  • 2

2 Answers2

7

Use the ISPF 'BNDS' line command command and set the bounds (via the '<' and '>' characters) to column 11 and column 20:

enter image description here

(Bounds are used to constrain scrolling, shift line commands ( ">", "<", ")", "(" ), text line commands ("TS", "TF", "TE") and FIND , CHANGE , EXCLUDE and SORT commands.)

Now use the '(' (Shift left) command to shift the data 2 characters to the left.

enter image description here

(We will use the '((' form of the '(' command to indicate that we are applying the '(' command to a block of rows and the default shift value is 2, which is what you want, so we don't have to specify a value).

The previously set bounds will ensure that only data in columns 11 through to 20 will be moved:

enter image description here

Steve Ives
  • 6,970
  • 3
  • 21
  • 49
0

Assuming that you want to remove the two spaces before 2005 and the two after 2005 and move the rest of the line four spaces to the left, you may follow these steps:

  1. Label 1st line to change .A
  2. Label last line to change .B
  3. Issue the command CHANGE ALL ' ' '' 13 20 .A .B

(note that the above command has 2 spaces between the quotes, then 0 spaces between the quotes).

Turophile
  • 3,157
  • 1
  • 10
  • 21