Portal | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Forum Index
 
Register
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
SYNCSORT Error - CONTROL FIELD BEYOND RECORD

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

New User


Joined: 03 Sep 2010
Posts: 15
Location: Bengaluru

PostPosted: Sun Oct 04, 2020 4:10 pm    Post subject: SYNCSORT Error - CONTROL FIELD BEYOND RECORD
Reply with quote

Re-posting as the previous post was posted in a non-syncsort forum. Apologies if it seems a duplicate.


I have a unique problem with how syncsort is working. My shop uses 2 mainframe environments - one runs on OS390 while other runs on Z/os 2 .
The job which performs sort and so far seems to be working perfectly in one mainframe system however the same job with same code is giving an error in different environment. The only visible difference i see is with the Syncsort for Z/os Version.
Below is the code snippet. Trying to understand what might possibly be wrong/incompatible here.

Log from the Code that works ----

Code:
SYNCSORT FOR Z/OS  2.1.4.1R
SYSIN :                                                             
 SORT FIELDS=(13,31,A,211,27,A,5,7,A),FORMAT=BI                     
                   
WER108I  SORTIN   : RECFM=VB   ; LRECL=   654; BLKSIZE= 27998       
WER073I  SORTIN   : DSNAME=INPUT.DATASET
WER110I  SORTOUT  : RECFM=VB   ; LRECL=   654; BLKSIZE= 27998       
WER074I  SORTOUT  : DSNAME=OUTPUT.DATASET
           
WER036B  G=1155                                                     
WER147I  CONTROL FIELD GREATER THAN RECORD LENGTH, POSSIBLE OUT OF SEQUENCE RECORD
WER177I  TURNAROUND SORT PERFORMED




Log from the same code in a different Mainframe environment that's failing.


Code:
SYNCSORT FOR Z/OS  2.1.0.0R
SYSIN :                                                                       
 SORT FIELDS=(13,31,A,211,27,A,5,7,A),FORMAT=BI                               
                 
WER108I  SORTIN   : RECFM=VB   ; LRECL=   654; BLKSIZE= 27998                 
WER073I  SORTIN   : DSNAME=INPUT.DATASET
WER110I  SORTOUT  : RECFM=VB   ; LRECL=   654; BLKSIZE= 27998                 
WER074I  SORTOUT  : DSNAME=OUTPUT.DATASET
WER462I  OUTPUT LRECL DIFFERS FROM SORTOUT LRECL                               
                   
WER036B  G=633                                                                 
WER027A  CONTROL FIELD BEYOND RECORD



Be Safe,
Thanks.
Back to top
View user's profile Send private message

sergeyken

Active Member


Joined: 29 Apr 2008
Posts: 860
Location: Maryland

PostPosted: Sun Oct 04, 2020 6:39 pm    Post subject:
Reply with quote

Your input records do have format VB, and you have got a particular one with LRECL<238 - hence your sort fields fell outside of the record field.

First of all, you need to decide: what to do with those short records? When decided, various solutions can be found to implement.
Back to top
View user's profile Send private message
arunn

New User


Joined: 03 Sep 2010
Posts: 15
Location: Bengaluru

PostPosted: Sun Oct 04, 2020 7:17 pm    Post subject: Reply to: SYNCSORT Error - CONTROL FIELD BEYOND RECORD
Reply with quote

There was an mistake in copying the output of the errored part - Posting the correct one here as not able to edit the one earlier and also the SORT step.

Code:
//*                                                             
//SORT     EXEC PGM=SORT                                       
//SYSOUT   DD SYSOUT=*                                           
//SORTIN   DD DSN=INPUT.DATASET,DISP=SHR    <<<< LRECL=654,RECFM=VB     
//SORTOUT  DD DSN=OUTPUT.DATASET,
//            DISP=(NEW,CATLG,DELETE),                           
//            SPACE=(CYL,(10,10),RLSE),                         
//            LRECL=654,RECFM=VB                                 
//SYSIN    DD *                                                 
 SORT FIELDS=(13,31,A,211,27,A,5,7,A),FORMAT=BI                 
//* 


Log from the successful run.
Code:
SYNCSORT FOR Z/OS  2.1.4.1R
SYSIN :                                                             
 SORT FIELDS=(13,31,A,211,27,A,5,7,A),FORMAT=BI                     
                   
WER108I  SORTIN   : RECFM=VB   ; LRECL=   654; BLKSIZE= 27998       
WER073I  SORTIN   : DSNAME=INPUT.DATASET
WER110I  SORTOUT  : RECFM=VB   ; LRECL=   654; BLKSIZE= 27998       
WER074I  SORTOUT  : DSNAME=OUTPUT.DATASET
           
WER036B  G=1155                                                     
WER147I  CONTROL FIELD GREATER THAN RECORD LENGTH, POSSIBLE OUT OF SEQUENCE RECORD
WER177I  TURNAROUND SORT PERFORMED


Log from the same code in a different Mainframe environment that's failing.
Code:
SYNCSORT FOR Z/OS  2.1.0.0R
SYSIN :                                                                       
 SORT FIELDS=(13,31,A,211,27,A,5,7,A),FORMAT=BI                               
                 
WER108I  SORTIN   : RECFM=VB   ; LRECL=   654; BLKSIZE= 27998                 
WER073I  SORTIN   : DSNAME=INPUT.DATASET
WER110I  SORTOUT  : RECFM=VB   ; LRECL=   654; BLKSIZE= 27998                 
WER074I  SORTOUT  : DSNAME=OUTPUT.DATASET
                                                         
WER036B  G=633                                                                                                       
WER027A  CONTROL FIELD BEYOND RECORD 


The record length of the input and output file being created is 654. No changes being done there on the length. I am confused about why its working in one environment and not the other?
Back to top
View user's profile Send private message
sergeyken

Active Member


Joined: 29 Apr 2008
Posts: 860
Location: Maryland

PostPosted: Sun Oct 04, 2020 7:22 pm    Post subject:
Reply with quote

I guess, you seriously need to RTFM.

With RECFM=VB, LRECL=654 each particular record can have any LRECL, between 4 and 654 bytes. Whenever your particular specific record is shorter than 238, you get the error you mentioned.

Again: RTFM, RTFM, and RTFM!!!

P.S.
Maybe, your different environments do have different SORT default options established, to ignore specific situations with records.
Anyway, you need to understand well all those details, starting from understanding LRECL when RECFM=VB...
Back to top
View user's profile Send private message
sergeyken

Active Member


Joined: 29 Apr 2008
Posts: 860
Location: Maryland

PostPosted: Sun Oct 04, 2020 11:23 pm    Post subject:
Reply with quote

If you read carefully the explanation of WER147W message (can you?) then you would easily find that SORT parameter VLTEST causes different behavior of the utility in those your two environments.

Why you are not able to read the manual before starting your screaming at the forum? Do you speak English?
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 2487
Location: NY,USA

PostPosted: Sun Oct 04, 2020 11:34 pm    Post subject:
Reply with quote

Try
Code:
OPTION COPY, VLSHRT

Besides, Syncsort releases don’t look the same and in one you already have a warning and in second that warning turned into an error. The error one looks to be the older version of the synsort.
Back to top
View user's profile Send private message
sergeyken

Active Member


Joined: 29 Apr 2008
Posts: 860
Location: Maryland

PostPosted: Sun Oct 04, 2020 11:46 pm    Post subject:
Reply with quote

Rohit Umarjikar wrote:
Try
Code:
OPTION COPY, VLSHRT


VLSHRT is an option for DFSORT utility, not for SYNCSORT.
Back to top
View user's profile Send private message
Joerg.Findeisen

Active User


Joined: 15 Aug 2015
Posts: 342
Location: Bamberg, Germany

PostPosted: Mon Oct 05, 2020 3:41 am    Post subject:
Reply with quote

From the manual:
Code:
VLTEST=(n/ 1 , ON /OFF /OFF4)  -> Indicates the type of validity testing to be done when processing variable-length records.

VLTESTI=n/ 0                   -> Indicates action to be taken when a variable-length record does not contain all fields referenced by INCLUDE or OMIT processing.
Back to top
View user's profile Send private message
sergeyken

Active Member


Joined: 29 Apr 2008
Posts: 860
Location: Maryland

PostPosted: Mon Oct 05, 2020 4:15 am    Post subject:
Reply with quote

Joerg.Findeisen wrote:
From the manual:
Code:
VLTEST=(n/ 1 , ON /OFF /OFF4)  -> Indicates the type of validity testing to be done when processing variable-length records.

VLTESTI=n/ 0                   -> Indicates action to be taken when a variable-length record does not contain all fields referenced by INCLUDE or OMIT processing.

If TS is not able to RTFM, then it is useless to quote the manual at the forum... 12.gif
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 2487
Location: NY,USA

PostPosted: Tue Oct 06, 2020 3:47 am    Post subject:
Reply with quote

sergeyken wrote:
Rohit Umarjikar wrote:
Try
Code:
OPTION COPY, VLSHRT


VLSHRT is an option for DFSORT utility, not for SYNCSORT.

That's correct.
If I remember VLTEST=1 is the default and equivalent of VLSHRT in DFSORT. So in SYNCSORT , if you provide VLSHRT then internally it will convert to VLTEST equivalent instead of a syntax error.
If TS make a use of PARM VLSTEST=1 then error should go away and on the side can as well try for OPTION COPY,VLSHRT.
Back to top
View user's profile Send private message
sergeyken

Active Member


Joined: 29 Apr 2008
Posts: 860
Location: Maryland

PostPosted: Tue Oct 06, 2020 5:18 am    Post subject:
Reply with quote

Rohit Umarjikar wrote:
sergeyken wrote:
Rohit Umarjikar wrote:
Try
Code:
OPTION COPY, VLSHRT


VLSHRT is an option for DFSORT utility, not for SYNCSORT.

That's correct.
If I remember VLTEST=1 is the default and equivalent of VLSHRT in DFSORT. So in SYNCSORT , if you provide VLSHRT then internally it will convert to VLTEST equivalent instead of a syntax error.
If TS make a use of PARM VLSTEST=1 then error should go away and on the side can as well try for OPTION COPY,VLSHRT.

The printed explanation of WER147I message clearly points to VLTEST parameter. The only thing the TS needs to do is, read the manual about this message found in his own log. Plus:<deleted by mod>
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 Copying data from prev record using SORT bshkris SYNCSORT 19 Thu Oct 15, 2020 3:29 pm
No new posts BMS map length field greater than zero Ziko13 CICS 3 Fri Oct 09, 2020 5:40 pm
No new posts Break a record into fields, each fiel... jackare SYNCSORT 2 Thu Oct 08, 2020 5:26 am
No new posts Creating a single-record file with CO... Joerg.Findeisen DFSORT/ICETOOL 8 Tue Oct 06, 2020 8:19 pm
No new posts Easytrieve EZABX007 with error code 0... Carol Schablow CA Products 7 Thu Sep 24, 2020 3:30 am

Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us