Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

SORTOUT LRECL issue in JOINKEY

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> SYNCSORT
View previous topic :: :: View next topic  
Author Message
Vinodh S

New User


Joined: 12 Apr 2012
Posts: 30
Location: LA, California

PostPosted: Tue Dec 18, 2012 10:29 pm    Post subject: SORTOUT LRECL issue in JOINKEY
Reply with quote

I'm trying to find out the delta changes between two files that is created today and the previous day.

The two input files are 25 bytes in LRECL. I have got the output as expected with respect to the Delta changes.

in the sortout i did not code the LRECL, Format and the Blocksize for the file and left it with the sort to create it with the best suited LRECL.

When i executed the job, the SORTOUT was created , but the LRECL of the SORTOUT file was 50 bytes.

I expected the SORTOUT to be 26 bytes. Since in my outrec build I write the Single Character I/U/D and then 25 bytes of field, either from F1 or from F2.

So i tried to give the LRECL=26, BLKSIZE=0 for the SORTOUT and but the SORT step abended and the SYSOUT pointed that the LRECL 26 is incompatible with SORTOUT.

Can some one tell why 50 byte file is created and if there is a way to create a SORTOUT file with just 26 bytes as LRECL.

Code:

JoinKeys Files=F1,FIELDS=(1,11,A,22,3,A)
JoinKeys Files=F2,FIELDS=(1,11,A,22,3,A)
JOINUNPAIRED,F1,F2
REFORMAT FIELDS=(F1:1,25,F2:1,25),FILL=X'FF'
OMIT COND=(1,25,CH,EQ,26,25)
SORT FIELDS=COPY
OUTREC IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,B1,EQ,X'FF'),
             BUILD=(C'I',1,25)),
IFTHEN=(WHEN=(2,1,BI,EQ,X'FF',AND,26,1,B1,NE,X'FF'),
             BUILD=(C'D',26,25)),
IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,B1,NE,X'FF'),
             BUILD=(C'U',1,25))
Back to top
View user's profile Send private message

Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7223

PostPosted: Tue Dec 18, 2012 11:21 pm    Post subject: Reply to: SORTOUT LRECL issue in JOINKEY
Reply with quote

If you are using DFSORT, you use the ? marker, not the FILL character, to identify match/mismatch in JOINKEYS.

Can you show your sysout from the step, please.
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Wed Dec 19, 2012 12:25 am    Post subject:
Reply with quote

Code:
OMIT COND=(1,25,CH,EQ,26,25)


shouldnt it be

Code:
OMIT COND=(1,25,CH,EQ,26,25,CH)
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7223

PostPosted: Wed Dec 19, 2012 3:58 am    Post subject: Reply to: SORTOUT LRECL issue in JOINKEY
Reply with quote

Yes, Pandora-Box. I think the cards were typed, rather than pasted, so highly unreliable.
Back to top
View user's profile Send private message
Vinodh S

New User


Joined: 12 Apr 2012
Posts: 30
Location: LA, California

PostPosted: Wed Dec 19, 2012 8:46 am    Post subject:
Reply with quote

The SYSOUT when i Coded the LRECL=26 for the SORTOUT statement.

Code:

******************************** Top of Data ***********************************
 SYNCSORT FOR Z/OS  1.4.0.1R    U.S. PATENTS: 4210961, 5117495   (C) 2010 SYNCSO
                                            z/OS   1.11.0   
 SYNCSORT LICENSED FOR CPU SERIAL NUMBER XXXXX, MODEL XXXX XXX             LICEN
 PARMEXIT : VSCORET=12M,MSG=SC                                                 
 SYSIN :                                                                       
  JOINKEYS FILES=F1,FIELDS=(1,11,A,22,3,A)                                     
  JOINKEYS FILES=F2,FIELDS=(1,11,A,22,3,A)                                     
  JOIN UNPAIRED,F1,F2                                                           
  REFORMAT FIELDS=(F1:1,25,F2:1,25),FILL=X'FF'                                 
  OMIT COND=(1,25,CH,EQ,26,25,CH)                                               
  SORT FIELDS=COPY                                                             
  OUTREC IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,BI,EQ,X'FF'),                   
          BUILD=(1:C'I',2:1,25)),                                               
  IFTHEN=(WHEN=(2,1,BI,EQ,X'FF',AND,26,1,BI,NE,X'FF'),                         
          BUILD=(1:C'D',2:26,25)),                                             
  IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,BI,NE,X'FF'),                         
          BUILD=(1:C'U',2:1,25))                                               
                                                                               
 WER161B  ALTERNATE PARM USED                                                   
 WER276B  SYSDIAG= 882539, 2952031, 2952031, 2300475                           
 WER164B  25,488K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,           
 WER164B     0 BYTES RESERVE REQUESTED, 988K BYTES USED                         
 WER146B  32K BYTES OF EMERGENCY SPACE ALLOCATED                               
 WER481I  JOINKEYS REFORMAT RECORD LENGTH=   50, TYPE = F                       
 WER237I  OUTREC RECORD LENGTH =    50                                         
 WER110I  SORTOUT  : RECFM=FB   ; LRECL=    26; BLKSIZE= 27976                 
 WER074I  SORTOUT  : DSNAME=TEST.WORK.TEMP.IUDEXTR                     
 WER247A  SORTOUT  HAS INCOMPATIBLE LRECL                                       
 WER211B  SYNCSMF  CALLED BY SYNCSORT; RC=0000                                 
 WER449I  SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE                                 
 WER482I  JNF1 STATISTICS                                                       
 WER483B  12,492K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,           
 WER483B     0 BYTES RESERVE REQUESTED, 988K BYTES USED                         
 WER108I  SORTJNF1 : RECFM=FB   ; LRECL=    25; BLKSIZE= 27975                 
 WER073I  SORTJNF1 : DSNAME=TEST.WORK.TEMP.EXTR.NEW                   
 WER482I  JNF2 STATISTICS                                                       
 WER483B  12,492K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,           
 WER483B     0 BYTES RESERVE REQUESTED, 988K BYTES USED                         
 WER108I  SORTJNF2 : RECFM=FB   ; LRECL=    25; BLKSIZE= 27975                 
 WER073I  SORTJNF2 : DSNAME=TEST.WORK.TEMP.EXTR.OLD                   
 ******************************* Bottom of Data ********************************



The sysout when LRECL was not coded in SORTOUT. Successful Run and the SORTOUT was created with LRECL=50.


Code:

******************************** Top of Data ***********************************
 SYNCSORT FOR Z/OS  1.4.0.1R    U.S. PATENTS: 4210961, 5117495   (C) 2010 SYNCSO
                                            z/OS   1.11.0   
 SYNCSORT LICENSED FOR CPU SERIAL NUMBER XXXXX, MODEL XXXX XXX             LICEN
 PARMEXIT : VSCORET=12M,MSG=SC                                                 
 SYSIN :                                                                       
  JOINKEYS FILES=F1,FIELDS=(1,11,A,22,3,A)                                     
  JOINKEYS FILES=F2,FIELDS=(1,11,A,22,3,A)                                     
  JOIN UNPAIRED,F1,F2                                                           
  REFORMAT FIELDS=(F1:1,25,F2:1,25),FILL=X'FF'                                 
  OMIT COND=(1,25,CH,EQ,26,25,CH)                                               
  SORT FIELDS=COPY                                                             
  OUTREC IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,BI,EQ,X'FF'),                   
          BUILD=(1:C'I',2:1,25)),                                               
  IFTHEN=(WHEN=(2,1,BI,EQ,X'FF',AND,26,1,BI,NE,X'FF'),                         
          BUILD=(1:C'D',2:26,25)),                                             
  IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,BI,NE,X'FF'),                         
          BUILD=(1:C'U',2:1,25))                                               
                                                                               
 WER161B  ALTERNATE PARM USED                                                   
 WER276B  SYSDIAG= 887796, 2957288, 2957288, 2300475                           
 WER164B  25,488K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,           
 WER164B     0 BYTES RESERVE REQUESTED, 1,167,272 BYTES USED                   
 WER146B  32K BYTES OF EMERGENCY SPACE ALLOCATED                               
 WER481I  JOINKEYS REFORMAT RECORD LENGTH=   50, TYPE = F                       
 WER237I  OUTREC RECORD LENGTH =    50                                         
 WER110I  SORTOUT  : RECFM=FB   ; LRECL=    50; BLKSIZE= 27950                 
 WER074I  SORTOUT  : DSNAME=TEST.WORK.TEMP.IUDEXTR                     
 WER410B  24,460K BYTES OF VIRTUAL STORAGE AVAILABLE ABOVE THE 16MEG LINE,     
 WER410B     0 BYTES RESERVE REQUESTED, 160K BYTES USED                         
 WER055I  INSERT          0, DELETE    2059736                                 
 WER211B  SYNCSMF  CALLED BY SYNCSORT; RC=0000                                 
 WER449I  SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE                                 
 WER416B  SORTOUT  : EXCP'S=7,UNIT=3390,DEV=303A,CHP=(4748494A5758595A,2),VOL=TS
 WER416B  TOTAL OF 7 EXCP'S ISSUED FOR COPYING                                 
 WER054I  RCD IN    2111421, OUT      51685                                     
 WER072I  NOEQUALS, BALANCE IN EFFECT                                           
 WER169I  RELEASE 1.4 BATCH 0520 TPF LEVEL 0.1                                 
 WER482I  JNF1 STATISTICS                                                       
WER483B  12,492K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,           
WER483B     0 BYTES RESERVE REQUESTED, 11,960K BYTES USED                     
WER108I  SORTJNF1 : RECFM=FB   ; LRECL=    25; BLKSIZE= 27975                 
WER073I  SORTJNF1 : DSNAME=TEST.WORK.TEMP.EXTR.NEW                   
WER483B  11,460K BYTES OF VIRTUAL STORAGE AVAILABLE ABOVE THE 16MEG LINE,     
WER483B     0 BYTES RESERVE REQUESTED, 11,472K BYTES USED                     
WER483B  G=65281,B=2266,BIAS=94                                               
WER483B  0 PREALLOCATED SORTWORK TRACKS, 1,080 DYNAMICALLY ALLOCATED,         
WER483B     0 ACQUIRED IN SECONDARY EXTENTS, 0 RELEASED, TOTAL OF 939 TRACKS US
WER484I  SORTJNF1 : RCD IN= 2110881,OMITTED= 0,PAIRED= 2110011,UNPAIRED= 870   
WER416B  SORTJNF1 : EXCP'S=23,UNIT=3390,DEV=BC1D,CHP=(7778797A8788898A,2),VOL=T
WER416B  JNF1WK01 : EXCP'S=33,UNIT=3390,DEV=38AB,CHP=4C4D4E4F5C5D5E5F,VOL=TEMP4
WER416B  JNF1WK02 : EXCP'S=17,UNIT=3390,DEV=389C,CHP=4C4D4E4F5C5D5E5F,VOL=TEMP7
WER416B  TOTAL OF 50 EXCP'S ISSUED FOR SORTWORKS                               
WER416B  TOTAL OF 73 EXCP'S ISSUED FOR SORTING                                 
WER487I  FILESIZE 52,772,025 BYTES                                             
WER482I  JNF2 STATISTICS                                                       
WER483B  12,492K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,           
WER483B     0 BYTES RESERVE REQUESTED, 11,960K BYTES USED                     
WER108I  SORTJNF2 : RECFM=FB   ; LRECL=    25; BLKSIZE= 27975                 
WER073I  SORTJNF2 : DSNAME=TEST.WORK.TEMP.EXTR.OLD                   
WER483B  11,460K BYTES OF VIRTUAL STORAGE AVAILABLE ABOVE THE 16MEG LINE,     
WER483B     0 BYTES RESERVE REQUESTED, 11,472K BYTES USED                     
WER483B  G=65281,B=2266,BIAS=94                                               
WER483B  0 PREALLOCATED SORTWORK TRACKS, 1,620 DYNAMICALLY ALLOCATED,         
WER483B     0 ACQUIRED IN SECONDARY EXTENTS, 0 RELEASED, TOTAL OF 939 TRACKS US
WER484I  SORTJNF2 : RCD IN= 2110551,OMITTED= 0,PAIRED= 2110011,UNPAIRED= 540   
WER416B  SORTJNF2 : EXCP'S=23,UNIT=3390,DEV=BE16,CHP=(7778797A8788898A,2),VOL=T
WER416B  JNF2WK01 : EXCP'S=35,UNIT=3390,DEV=3881,CHP=4C4D4E4F5C5D5E5F,VOL=TEMP5
WER416B  JNF2WK02 : EXCP'S=13,UNIT=3390,DEV=3893,CHP=4C4D4E4F5C5D5E5F,VOL=TEMP8
WER416B  JNF2WK03 : EXCP'S=5,UNIT=3390,DEV=3894,CHP=4C4D4E4F5C5D5E5F,VOL=TEMP81
WER416B  TOTAL OF 53 EXCP'S ISSUED FOR SORTWORKS                               
WER416B  TOTAL OF 76 EXCP'S ISSUED FOR SORTING                                 
WER487I  FILESIZE 52,763,775 BYTES                                             
WER052I  END SYNCSORT - TESTJOBX,STEP150,,DIAG=EE00,61C8,C28C,00CE,A672,48E3,86
WER052I  DIAG1=8200,D810,AA9C,EC66,CB73,6C8B,2200,C760                         
WER052I  DIAG2=8400,DA12,A89C,ECE4,CD73,688B,2600,C560                         
******************************* Bottom of Data ********************************

Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7223

PostPosted: Wed Dec 19, 2012 9:11 am    Post subject: Reply to: SORTOUT LRECL issue in JOINKEY
Reply with quote

Can you show a few of the output records, please, from the step which wrote 50 bytes?
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Wed Dec 19, 2012 9:16 am    Post subject:
Reply with quote

Also what is the sysout you get when you dont code DCB
What made you think to have LRECL=50?
Back to top
View user's profile Send private message
Vinodh S

New User


Joined: 12 Apr 2012
Posts: 30
Location: LA, California

PostPosted: Wed Dec 19, 2012 10:32 am    Post subject:
Reply with quote

Hi Pandora

I have already posted both the SYSOUT in my previous post. Posting here a small version for clarity. Please refer the previous post for the complete SYSOUT details.

The First SYSOUT I have posted is when I coded the DCB in the SORTOUT. Job abended, ABEND=S000 U0016.
Code:

 WER481I  JOINKEYS REFORMAT RECORD LENGTH=   50, TYPE = F                       
 WER237I  OUTREC RECORD LENGTH =    50                                         
 WER110I  SORTOUT  : RECFM=FB   ; LRECL=    26; BLKSIZE= 27976                 
 WER074I  SORTOUT  : DSNAME=TEST.WORK.TEMP.IUDEXTR                     
 WER247A  SORTOUT  HAS INCOMPATIBLE LRECL       


The Second SYSOUT correponds to the JCL where I did not code the DCB for the SORTOUT. The Job ran fine.

Code:

 WER481I  JOINKEYS REFORMAT RECORD LENGTH=   50, TYPE = F                       
 WER237I  OUTREC RECORD LENGTH =    50                                         
 WER110I  SORTOUT  : RECFM=FB   ; LRECL=    50; BLKSIZE= 27950                 
 WER074I  SORTOUT  : DSNAME=TEST.WORK.TEMP.IUDEXTR   


@ BILL

Will post the sample records shortly.
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Wed Dec 19, 2012 10:46 am    Post subject:
Reply with quote

Also post your complete JCL STEP
Back to top
View user's profile Send private message
Vinodh S

New User


Joined: 12 Apr 2012
Posts: 30
Location: LA, California

PostPosted: Wed Dec 19, 2012 11:39 am    Post subject:
Reply with quote

JCl Where the DCB was coded for the SORTOUT.

Code:

000146 //STEP150  EXEC PGM=SORT,COND=(0,NE)                                   
000147 //******************************************************************   
000148 //***       STEP FUNCTION  : COMPARE TO GET I/U/D                  *   
000153 //******************************************************************   
000154 //SYSOUT   DD SYSOUT=*                                                 
000155 //SYSPRINT DD SYSOUT=*                                                 
000156 //*                                                                     
000160 //SORTJNF1 DD DSN=TEST.WORK.TEMP.EXTR.NEW,                     
000161 //         DISP=SHR                                                     
000162 //*                                                                     
000163 //SORTJNF2 DD DSN=TEST.WORK.TEMP.EXTR.OLD,                     
000164 //         DISP=SHR                                                     
000165 //*                                                                     
000166 //SORTOUT  DD DSN=TEST.WORK.TEMP.IUDEXTR,                     
000167 //         DISP=(NEW,CATLG,DELETE),                                     
000168 //         DCB=(LRECL=26,RECFM=FB,BLKSIZE=0),                           
000169 //         SPACE=(CYL,(10,100),RLSE)                                   
000170 //*                                                                     
000171 //SYSIN    DD DSN=TEST.WORK.TEMP.CNTL(IUDTEST),                 
000172 //         DISP=SHR                                                     
****** **************************** Bottom of Data ****************************


Corresponding SYSOUT:

Code:

Code:
 WER481I  JOINKEYS REFORMAT RECORD LENGTH=   50, TYPE = F                       
 WER237I  OUTREC RECORD LENGTH =    50                                         
 WER110I  SORTOUT  : RECFM=FB   ; LRECL=    26; BLKSIZE= 27976                 
 WER074I  SORTOUT  : DSNAME=TEST.WORK.TEMP.IUDEXTR                     
 WER247A  SORTOUT  HAS INCOMPATIBLE LRECL       


-------------------


JCl Where the DCB was not coded for the SORTOUT.

Code:

000147 //STEP150  EXEC PGM=SORT,COND=(0,NE)                                   
000148 //******************************************************************   
000149 //***       STEP FUNCTION  : COMPARE TO GET I/U/D                  *   
000154 //******************************************************************   
000155 //SYSOUT   DD SYSOUT=*                                                 
000156 //SYSPRINT DD SYSOUT=*                                                 
000160 //*                                                                     
000161 //SORTJNF1 DD DSN=TEST.WORK.TEMP.EXTR.NEW,                     
000162 //         DISP=SHR                                                     
000163 //*                                                                     
000164 //SORTJNF2 DD DSN=TEST.WORK.TEMP.EXTR.OLD,                     
000165 //         DISP=SHR                                                     
000166 //*                                                                     
000167 //SORTOUT  DD DSN=TEST.WORK.TEMP.IUDEXTR,                     
000168 //         DISP=(NEW,CATLG,DELETE),                                     
000170 //         SPACE=(CYL,(10,100),RLSE)                                   
000171 //*                                                                     
000172 //SYSIN    DD DSN=TEST.WORK.TEMP.CNTL(IUDTEST),                 
000173 //         DISP=SHR                                                     
****** **************************** Bottom of Data ****************************


Corresponding SYSOUT:

Code:

 WER481I  JOINKEYS REFORMAT RECORD LENGTH=   50, TYPE = F                       
 WER237I  OUTREC RECORD LENGTH =    50                                         
 WER110I  SORTOUT  : RECFM=FB   ; LRECL=    50; BLKSIZE= 27950                 
 WER074I  SORTOUT  : DSNAME=TEST.WORK.TEMP.IUDEXTR 


For a complete SYSOUT, please refer my previous post.
Back to top
View user's profile Send private message
chandan.inst

Active User


Joined: 03 Nov 2005
Posts: 269
Location: Mumbai

PostPosted: Wed Dec 19, 2012 11:59 am    Post subject:
Reply with quote

Hi,

It seems it's taking REFORMAT fields length as out put file length.

What is coming in remaining 24 bytes in output file when you are executing it witout giving LRECL

You can try using SORTOF01 / OUTFIL FILES = 01 instead of SORTOUT

Regards,
Chandan
Back to top
View user's profile Send private message
Vinodh S

New User


Joined: 12 Apr 2012
Posts: 30
Location: LA, California

PostPosted: Wed Dec 19, 2012 12:36 pm    Post subject:
Reply with quote

Sample records in the FIle.

New File, F1

Code:

New File:

----+----1----+----2----+
BSGF012900205/17/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900205117120120508
 ------------------------
BSGF012900205/24/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900205124120120408
 ------------------------
BSGF012900206/07/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900206107120120208
 ------------------------
BSGF012900206/14/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900206114120120108
 ------------------------
BSGF012900206/21/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900206121120120008
 ------------------------


Old File, F2 :

Code:

----+----1----+----2----+
BSGF012900205/10/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900205110120120508
 ------------------------
BSGF012900205/17/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900205117120120408
 ------------------------
BSGF012900205/24/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900205124120120308
 ------------------------
BSGF012900206/07/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900206107120120108
 ------------------------
BSGF012900206/14/2012...Y
CECCFFFFFFFFF6FF6FFFF020E
2276012900206114120120008
 ------------------------


Output Extract File:

Code:

IUD file:(with HEX ON)   


----+----1----+----2----+----3----+----4----+----5       
UBSGF012900206/21/2012...Y                               
ECECCFFFFFFFFF6FF6FFFF020E444444444444444444444444       
42276012900206121120120008000000000000000000000000       
----------------------------------------------------------
UBSGF012900206/14/2012...Y                               
ECECCFFFFFFFFF6FF6FFFF020E444444444444444444444444       
42276012900206114120120108000000000000000000000000       
----------------------------------------------------------
IBSGF012900206/07/2012...Y                               
CCECCFFFFFFFFF6FF6FFFF020E444444444444444444444444       
92276012900206107120120208000000000000000000000000       
----------------------------------------------------------
DBSGF012900205/24/2012...Y                               
CCECCFFFFFFFFF6FF6FFFF020E444444444444444444444444       
42276012900205124120120308000000000000000000000000       
----------------------------------------------------------
UBSGF012900205/24/2012...Y                               
ECECCFFFFFFFFF6FF6FFFF020E444444444444444444444444       
42276012900205124120120408000000000000000000000000       
----------------------------------------------------------
UBSGF012900205/17/2012...Y                               
ECECCFFFFFFFFF6FF6FFFF020E444444444444444444444444       
42276012900205117120120508000000000000000000000000       
Back to top
View user's profile Send private message
Vinodh S

New User


Joined: 12 Apr 2012
Posts: 30
Location: LA, California

PostPosted: Wed Dec 19, 2012 12:46 pm    Post subject:
Reply with quote

Hi Chandan

The SORTOF01 did work as per my expectation icon_smile.gif
thanks a lot.
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Wed Dec 19, 2012 12:53 pm    Post subject:
Reply with quote

I still couldnt believe OUTFIL did the trick but then why didnt it work with OUTREC

May be OUTREC should be replaced by INREC?

A good topic for discussion I believe

Experts need your intervention

Also with all due respect to SYNCSORT .. I didn't get issue in DFSORT icon_confused.gif

I know I shouldnt compare both but yet thought of stating it
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7223

PostPosted: Wed Dec 19, 2012 1:29 pm    Post subject: Reply to: SORTOUT LRECL issue in JOINKEY
Reply with quote

I'd have used

Code:
   BUILD=(C'I',1,25)),


and had them on INREC.

It is doing the processing, and then using 50 (the copy of length from input (REFORMAT here) to output is normal, unless data adjusted in length), even "padding" with spaces from the 26, Sort "knows" the records are 26, but also, somehow, "knows" you want a record-length of 50 (which you don't).

I think you need to raise an issue with SyncSort.
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7223

PostPosted: Thu Dec 20, 2012 3:17 am    Post subject: Reply to: SORTOUT LRECL issue in JOINKEY
Reply with quote

I suspect this:

Code:
  INREC IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,BI,EQ,X'FF'),                   
                 BUILD=(C'I',1,25)),                                               
        IFTHEN=(WHEN=(2,1,BI,EQ,X'FF',AND,26,1,BI,NE,X'FF'),                         
                 BUILD=(C'D',26,25)),                                             
        IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,BI,NE,X'FF'),                         
                 BUILD=(C'U',1,25))   


Or this:

Code:
  INREC IFOUTLEN=26,
      IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,BI,EQ,X'FF'),                   
               BUILD=(C'I',1,25)),                                               
      IFTHEN=(WHEN=(2,1,BI,EQ,X'FF',AND,26,1,BI,NE,X'FF'),                         
               BUILD=(C'D',26,25)),                                             
      IFTHEN=(WHEN=(2,1,BI,NE,X'FF',AND,26,1,BI,NE,X'FF'),                         
               BUILD=(C'U',1,25)) 


will work.

The IFOUTLEN can be used to set the length of the output from IFTHEN statements. It is not always possible for Sort to "keep track" of values across all IFTHENs. I can at the moment only think that the columns were "confusing" the issue.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Dec 20, 2012 4:30 am    Post subject:
Reply with quote

Hi,

I have run it thru DFSORT and the output LRECL for SORTOUT is 50.


Actually, it makes sense that the LRECL is 50.

If all the IFTHEN statements do not satisfy the criteria, the record to be written out is 50 bytes long.


Gerry
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Thu Dec 20, 2012 10:38 am    Post subject:
Reply with quote

Code:
//INA      DD *
AAA  123
DBB  345
EBB  345
FBB  345
//INB      DD *
AAA  354
BBB  345
CBB  345
FBB  345
//SORTOUT DD DSN=PANDORA.MIMAT.CM006,DISP=(NEW,CATLG,DELETE),
//            SPACE=(CYL,(5,5),RLSE)
//SYSIN    DD *
  OPTION COPY
  JOINKEYS F1=INA,FIELDS=(1,3,A)
  JOINKEYS F2=INB,FIELDS=(1,3,A)
  JOIN UNPAIRED,F1,F2
  REFORMAT FIELDS=(F1:1,10,F2:1,10),FILL=X'FF'
  OMIT COND=(1,10,CH,EQ,11,10,CH)
  INREC IFOUTLEN=10,
        IFTHEN=(WHEN=(1,1,BI,NE,X'FF',AND,11,1,BI,EQ,X'FF'),
               BUILD=(1:C'I',2:1,10)),
        IFTHEN=(WHEN=(1,1,BI,EQ,X'FF',AND,11,1,BI,NE,X'FF'),
               BUILD=(1:C'D',2:11,10)),
        IFTHEN=(WHEN=(1,1,BI,NE,X'FF',AND,11,1,BI,NE,X'FF'),
               BUILD=(1:C'U',2:1,10))


Yes this gives the LRECL 10 but though without IFOUTLEN we dont get the error

Quote:
IFOUTLEN
 IFOUTLEN=n

INREC Control Statement

Overrides the INREC LRECL (or reformatted record length if the INREC record
is further modified) determined by DFSORT from your INREC IFTHEN
clauses. DFSORT sets an appropriate LRECL for the output records based on
the build, overlay, find/replace and group operation items specified by the
IFTHEN clauses. However, DFSORT does not analyze the possible results of
WHEN=(logexp) conditions when determining an appropriate INREC LRECL.
When you use INREC IFTHEN clauses, you can override the INREC LRECL
determined by DFSORT with the INREC IFOUTLEN parameter.
Fixed-length records longer than the IFOUTLEN length are truncated to the
IFOUTLEN length. Fixed-length records shorter than the IFOUTLEN are
padded with blanks to the IFOUTLEN length. Variable-length records longer
than the IFOUTLEN length are truncated to the IFOUTLEN length.
n specifies the length to use for the INREC LRECL (or for the reformatted
record length if the INREC record is further modified) . The value for n
must be between 1 and 32767, but must not be larger than the maximum
LRECL allowed for the RECFM, and must not conflict with the specified or
retrieved LRECL for the fixed-length output data set.


From DFSORT Manual and this is pretty clear now
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> SYNCSORT All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts DFHRESPONSE returns issue divated CICS 3 Wed Nov 02, 2016 6:32 pm
No new posts Can sending 5 MB data between cobol p... Kevin Vaz CICS 12 Tue Oct 18, 2016 4:50 pm
No new posts Using 'parm' to vary SORTOUT record v... Sysaron DFSORT/ICETOOL 13 Wed Sep 07, 2016 9:24 pm
No new posts PL/I: opening file w/ dynamically det... Sam Dodgers PL/I & Assembler 6 Wed Jul 27, 2016 4:05 pm
No new posts Syncsort Joinkey nartcr SYNCSORT 2 Thu Jun 02, 2016 3:46 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us