View previous topic :: View next topic
Author
Message
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
Hi all, I've the code below.
//*
//STEP010 EXEC PGM=SORT,REGION=0K
//SYSOUT DD SYSOUT=*
//SYSDBOUT DD SYSOUT=*
//SORPRINT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SORTIN DD DSN=MIFENDPV.PROD.ENFA07K,DISP=SHR
//SORTOUT DD DSN=&&ENFTR01,DISP=(,PASS),
// SPACE=(TRK,(1,1),RLSE),
// DCB=(RECFM=FB,LRECL=80,BUFNO=5)
//SYSIN DD *
SORT FIELDS=COPY
INCLUDE COND=(1,3,CH,EQ,C'002')
OUTREC FIELDS=(4,6,7,73,C' ')
This give me an output like this "200709 "
I want to create a sort card like this below including the variable "200709 "
Can i do it???
SORT FIELDS=COPY
INCLUDE COND=(266,1,CH,EQ,C'S',AND,
43,8,CH,EQ,C'200709 ',AND,
126,1,CH,NE,C'S')
Thanks a lot
Back to top
Aaru Senior Member Joined: 03 Jul 2007Posts: 1287 Location: Chennai, India
miosne,
Quote:
I want to create a sort card like this below including the variable "200709"
Can i do it???
Yes,you can. Try and let us know the results.
Back to top
Aaru Senior Member Joined: 03 Jul 2007Posts: 1287 Location: Chennai, India
miosne,
Quote:
43,8 ,CH,EQ,C'200709',
why is the length coded as 8 instead of 6?
Back to top
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
sorry, the code is "43,6,ch,eq,c'200709' "
Back to top
Aaru Senior Member Joined: 03 Jul 2007Posts: 1287 Location: Chennai, India
Quote:
sorry, the code is "43,6,ch,eq,c'200709'"
Ok. Yes you can use this sort condition in your sort card if your requirement is to check if the 6 digits starting from 43rd position is 200709.
Back to top
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
Aaru, I've to catch the parameter '200709 ' from the STEP010 and creating a dinamic sort card like the example.
Back to top
Aaru Senior Member Joined: 03 Jul 2007Posts: 1287 Location: Chennai, India
miosne,
Quote:
creating a dinamic sort card like the example
What actually is your requirement? you never mentioned that you wanted to create a dynamic sort card in your first post.
Quote:
ve to catch the parameter '200709' from the STEP010
Even your SORT card is in step10 and from where are you fetching "200709".
Please explain your requirements clealy so that people can help you.
Back to top
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
Hte output from STEP010 is the parameter that i want to put in the sort card below.(red)
I want to create the sort card below including the date from the STEP010.
SORT FIELDS=COPY
INCLUDE COND=(266,1,CH,EQ,C'S',AND,
43,8,CH,EQ,C'200709 ',AND,
126,1,CH,NE,C'S')
Back to top
krisprems Active Member Joined: 27 Nov 2006Posts: 649 Location: India
miosne
Change you STEP10 SYSIN like this
Code:
SORT FIELDS=COPY
INCLUDE COND=(1,3,CH,EQ,C'002')
OUTFIL BUILD=(2:C'SORT FIELDS=COPY ',80:X,/,
2:C'INCLUDE COND=(266,1,CH,EQ,C''S'',AND,',80:X,/,
2:C'4,6,CH,EQ,C''',4,6,C''',AND,',80:X,/,
2:C'126,1,CH,NE,C''S'')',80:X)
this will generate a SORTCARD like this
Code:
SORT FIELDS=COPY
INCLUDE COND=(266,1,CH,EQ,C'S',AND,
4,6,CH,EQ,C'XXXXXX',AND,
126,1,CH,NE,C'S')
XXXXXX will be generated dynamically
Back to top
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
The rc is equal 12:
Code:
SYNCSORT FOR Z/OS 1.1DR TPF3A U.S. PATENTS:
CEDACRI
PRODUCT LICENSED FOR CPU SERIAL NUMBER 4C2AD, M
SYSIN :
SORT FIELDS=COPY
INCLUDE COND=(1,3,CH,EQ,C'002')
OUTFIL BUILD=(2:C'SORT FIELDS=COPY ',80:X,/,
*
2:C'INCLUDE COND=(266,1,CH,EQ,C'
2:C'4,6,CH,EQ,C''',4,6,C''',AND,
2:C'126,1,CH,NE,C''S'')',80:X)
WER268A OUTFIL STATEMENT : SYNTAX ERROR
WER211B SYNCSMF CALLED BY SYNCSORT; RC=0000
WER449I SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE
Back to top
krisprems Active Member Joined: 27 Nov 2006Posts: 649 Location: India
miosne
The SORT card that i posted was a tested one... wonder why you got this SYNTAX error?
Try changing that BUILD to OUTREC
Back to top
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
It works.
Thank'you very much.
saluti dall'italia.
Back to top
krisprems Active Member Joined: 27 Nov 2006Posts: 649 Location: India
miosne
Is that working, after changing BUILD to OUTREC?
Or you had anyother syntax mistakes?
Back to top
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
no, I've only follow your indication.
I've substitute BUILD with OUTREC!!!!
Can I ask you another thing???
or you prefer that I open another topic??
Back to top
krisprems Active Member Joined: 27 Nov 2006Posts: 649 Location: India
Quote:
SYNCSORT FOR Z/OS 1.1DR
Since your SYNCSORT was old version i guessed it wont have the the SYNTAX for BUILD under OUTFIL.
It was just a guess.
Some how you got it right
Quote:
Can I ask you another thing???
or you prefer that I open another topic??
If that question is related to same topic then go ahead and ask, else open a new topic
Back to top
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
ok, I open a new topic
Back to top
vicky10001 Warnings : 1 Active User Joined: 13 Jul 2005Posts: 136
SORT FIELDS=(59,4,BI,A,4,8,CH,A),EQUALS
OUTREC FIELDS=(1:1,13,
14:16X,
30:30,1)
Please use the above sysin
Back to top
miosne Warnings : 1 New User Joined: 13 Mar 2006Posts: 63 Location: italy
what do you mean???
Back to top
Please enable JavaScript!