View previous topic :: View next topic
|
Author |
Message |
SENTHIL MURUGAAN Warnings : 1 New User
Joined: 12 Jan 2013 Posts: 32 Location: India
|
|
|
|
Hi,
I have the input file as below.
Code: |
Code:
DEP100 REC AA100
DEP101 ERR AARRR
DEP102 REC AA200
|
In the above input file, if position (8:3) = REC, then copy (1:6) from input file to (18:6) in output file as shown below. Is there any way to achieve this in JCL sort?
Code: |
Code:
DEP100 REC AA100 DEP100
DEP101 ERR AARRR
DEP102 REC AA200 DEP102
|
Thanks,
Senthil[/img] |
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
You can achieve this using the 'IFTHEN' parameter.
Search the forum and you will find lot of working examples. |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
|
|
|
|
What do you mean by 'JCL sort'? I know of no sort product called JCL and if the other interpretation of 'JCL sort' is 'sorting JCL' how do you expect that to do what you want? |
|
Back to top |
|
|
SENTHIL MURUGAAN Warnings : 1 New User
Joined: 12 Jan 2013 Posts: 32 Location: India
|
|
|
|
Hi Nic,
I was referring to Sort card in JCL and to say in short I stated as JCL sort and working with IFTHEN syntax as suggested by Arun. Thanks
Thanks,
Senthil |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
|
|
|
|
Sort card and JCL are NOT the same thing - JCL is JCL, sort cards are conrol cards for the sort program which may, or may not, be invoked directly from JCL. Do not mix them up. JCL 'cards' will be found in the JCL Language reference manual, sort control cards in the sort reference manual. |
|
Back to top |
|
|
SENTHIL MURUGAAN Warnings : 1 New User
Joined: 12 Jan 2013 Posts: 32 Location: India
|
|
|
|
I got the solution for IFTHEN syntax thanks
Thanks,
Senthil |
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
Senthil
Good that you worked it out by yourself. Btw as Nic suggested terminology is really important and we should be clear with that especially while asking questions. |
|
Back to top |
|
|
|