IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

ICE218A 6 12 BYTE VARIABLE RECORD IS SHORTER THAN 19 BYTE MI


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Rimjhim

New User


Joined: 18 May 2022
Posts: 12
Location: India

PostPosted: Thu May 26, 2022 8:14 pm
Reply with quote

Greetings All,

My requirement is to copy records from one VSAM. The records which need to be copied should have ~~~~~ from 10th col to 15th.
Below is the JCL


//STEP020 EXEC PGM=ICEMAN
//SORTIN DD DSN=RS28753.B.A.D220526,DISP=SHR
//OUT1 DD DSN=RS28753.B.A.D220526.A,DISP=SHR
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
OPTION COPY
INCLUDE COND=(15,5,CH,EQ,C'~~~~~')
OUTFIL FNAMES=OUT1,BUILD=(1,4,4304:X),VLFILL=C' '

Both input and output files have
Record format . . . : VB
Record length . . . : 4304

The error I am getting is:

ICE907I 1 ST=BELOW,SA=49736,NF=1,LF=49736,SF=49736
ICE855I 0 OUT1 : TX=N, R=D, L=D, B=D, BL=0, BR=0, DCT=37, VS=N, RU=X, SB=8
ICE218A 6 12 BYTE VARIABLE RECORD IS SHORTER THAN 19 BYTE MINIMUM FOR F
ICE751I 1 EF-BASE CB-BASE F0-BASE E8-I49502
ICE052I 0 END OF DFSORT

Please help me here

Thanks and Regards
Rimjhim
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2021
Location: USA

PostPosted: Thu May 26, 2022 9:16 pm
Reply with quote

1. This is neither JCL, nor VSAM issue. This tool is called ICETOOL/DFSORT utility.

2. Please, learn how to use the Code button, when posting your samples at the forum.

Rimjhim wrote:
Greetings All,

My requirement is to copy records from one VSAM. The records which need to be copied should have ~~~~~ from 10th col to 15th.
Below is the JCL


Code:
//STEP020  EXEC PGM=ICEMAN                                             
//SORTIN DD DSN=RS28753.B.A.D220526,DISP=SHR               
//OUT1   DD DSN=RS28753.B.A.D220526.A,DISP=SHR             
//SYSOUT DD SYSOUT=*                                                   
//SYSPRINT DD SYSOUT=*                                                 
//SYSIN DD *                                                           
  OPTION COPY                                                         
  INCLUDE COND=(15,5,CH,EQ,C'~~~~~')                                   
  OUTFIL FNAMES=OUT1,BUILD=(1,4,4304:X),VLFILL=C' '             

Both input and output files have
Record format . . . : VB
Record length . . . : 4304

The error I am getting is:

Code:
ICE907I 1 ST=BELOW,SA=49736,NF=1,LF=49736,SF=49736                             
ICE855I 0 OUT1     : TX=N, R=D, L=D, B=D, BL=0, BR=0, DCT=37, VS=N, RU=X, SB=8 
ICE218A 6 12 BYTE VARIABLE RECORD IS SHORTER THAN 19 BYTE MINIMUM FOR          F
ICE751I 1 EF-BASE   CB-BASE   F0-BASE   E8-I49502                               
ICE052I 0 END OF DFSORT

Please help me here

Thanks and Regards
Rimjhim


3. Looks like your input has RECFM=VB or RECFM=FB format, and there is (at least one) record of length 12 bytes:
Code:
ICE218A 6 12 BYTE VARIABLE RECORD IS SHORTER THAN 19 BYTE MINIMUM FOR          F????????????????

But one of your SORT utility statements requires the minimum record length of 19 bytes (15+5-1):
Code:
  INCLUDE COND=(15,5,CH,EQ,C'~~~~~')   


Please, RTFM: how to deal with too short VB records? There are several VL-like parameters to handle this issue properly.


P.S.
Important! Do not try to find any explanation neither in JCL, nor in VSAM manuals!
Back to top
View user's profile Send private message
Rimjhim

New User


Joined: 18 May 2022
Posts: 12
Location: India

PostPosted: Thu May 26, 2022 9:38 pm
Reply with quote

@sergeyken, I have made the corrections.
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2021
Location: USA

PostPosted: Thu May 26, 2022 9:41 pm
Reply with quote

Rimjhim wrote:
@sergeyken, I have made the corrections.

You major problem is, dealing with incorrect record length.

Have you fixed it?
Or at least: did you find what is actually wrong in your input data, and/or SORT utility statements and parameters?
Back to top
View user's profile Send private message
Rimjhim

New User


Joined: 18 May 2022
Posts: 12
Location: India

PostPosted: Thu May 26, 2022 9:43 pm
Reply with quote

No, the issue is still not fixed. By correction I meant I have posted the question in the ICETOOLS topic and added the CODE utility.

The issue still persists
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2021
Location: USA

PostPosted: Thu May 26, 2022 9:49 pm
Reply with quote

Rimjhim wrote:
No, the issue is still not fixed. By correction I meant I have posted the question in the ICETOOLS topic and added the CODE utility.

The issue still persists


You need to find out:

1) what are the DCB attributes of your input dataset? (RECFM, LRECL, BLKSIZE)

2) what are the actual physical records in you test input dataset? (you can use the straightforward output from SORT utility, without any selection or conversion)

3) depending on the results of 1-2, you need to find the way to resolve your issue.

With not enough information, no-one would be able to help you...
Back to top
View user's profile Send private message
Rimjhim

New User


Joined: 18 May 2022
Posts: 12
Location: India

PostPosted: Thu May 26, 2022 10:00 pm
Reply with quote

Input file Info:
Code:

 Data class . . . . . : NULLDSN                                     
  Organization  . . . : PS             Current Utilization         
  Record format . . . : VB              Used blocks . . . . : 3     
  Record length . . . : 4304            Used extents  . . . : 1     
  Block size  . . . . : 27998                                       
  1st extent blocks . : 4                                           
  Secondary blocks  . : 2              Dates                       
  Data set name type  :                 Creation date . . . : 2022/0


Input Data:

Here, there are many records like this and we need to only include the ones which look like 2022-05-26 BHB.

Code:

CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP     2022-05-26    BHB           
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2021
Location: USA

PostPosted: Thu May 26, 2022 10:41 pm
Reply with quote

Code:

  Record format . . . : VB              Used blocks . . . . : 3     
  Record length . . . : 4304            Used extents  . . . : 1     


With RECFM=VB the character positions are calculated by SORT utility including 4-byte RDW prefix. So, the visually first character will have position 5 within the record.

LRECL=4304 defined the maximum allowed record length within this dataset. Real records may have any length, from 5 to 4304 bytes physically, or from 1 to 4300 bytes logically.

You can verify the length of your records in your SORT statements, by using ...,BUILD=(1,2,BI,...) to print out the record length as decimal number. This may help you to detect the short records.

For your initial example, you can use INCLUDE COND=(1,2,BI,LT,+19) to select short records, and to make the decision: how to deal with them?

Quote:
Here, there are many records like this and we need to only include the ones which look like 2022-05-26 BHB.


Code:

CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP     2022-05-26    BHB           
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB
CONABN-JKP    02345459323 2022-05-26    BHB


How do you plan to verify your key field located at different offsets for different records?
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3051
Location: NYC,USA

PostPosted: Fri May 27, 2022 10:34 am
Reply with quote

OP needs the option VLSCMP. Moved the topic to DFSORT Section.
Back to top
View user's profile Send private message
Rimjhim

New User


Joined: 18 May 2022
Posts: 12
Location: India

PostPosted: Mon May 30, 2022 7:21 am
Reply with quote

Hello,

My requirement changed but the issue remains.

Now the requirement is, in the input file we get details like email id. We need to strip off records which do not have the email id.

I am using the below sort card
Code:

//SYSIN DD *                                           
  OPTION COPY                                           
  INCLUDE COND=(1,291,SS,EQ,C'.COM')                   
  INREC IFTHEN=(WHEN=(1,2,BI,LT,291),OVERLAY=(291:X))   
/*                                                     
                                                       


The output is sent to SYSOUT and the inpur file details are as below
Code:

Data class . . . . . : NULLDSN                                         
 Organization  . . . : PS             Current Utilization               
 Record format . . . : VB              Used blocks . . . . : 3         
 Record length . . . : 291             Used extents  . . . : 1         
 Block size  . . . . : 27998                                           
 1st extent blocks . : 4                                               
 Secondary blocks  . : 2              Dates                             
 Data set name type  :                 Creation date . . . : 2022/05/30


Error I am getting
ICE218A 6 100 BYTE VARIABLE RECORD IS SHORTER THAN 291 BYTE MINIMUM FOR

Please help me understand the issue. Operations on VB files confuses me.
Back to top
View user's profile Send private message
Rimjhim

New User


Joined: 18 May 2022
Posts: 12
Location: India

PostPosted: Mon May 30, 2022 7:39 am
Reply with quote

Further, I looked up the IBM docs(https://www.ibm.com/docs/en/zos/2.3.0?topic=messages-ice218a) for this error and it says that in case of INCLUDE I should use VLSHRT so I modified my SORT card to look like

Code:

//SYSIN DD *                                           
  OPTION COPY,VLSHRT                                   
  INCLUDE COND=(1,291,SS,EQ,C'.COM')                   
  INREC IFTHEN=(WHEN=(1,2,BI,LT,291),OVERLAY=(291:X))   
/*         



Still, same abend. Kindly advise
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2021
Location: USA

PostPosted: Mon May 30, 2022 7:42 am
Reply with quote

If you explicitly select only records shorter than 291 bytes, then you cannot OVERLAY non-existing byte at position 291 to whatever else.

It is as clear as a sunny day.

For instance, you can try to BUILD a new record; maybe, like this
Code:
 …,BUILD=(1,4,291:X),…
Back to top
View user's profile Send private message
Rimjhim

New User


Joined: 18 May 2022
Posts: 12
Location: India

PostPosted: Mon May 30, 2022 7:46 am
Reply with quote

I first ran the job without the VLSHRT, still same error.

It is then I went through the IBM docs to see what I am missing.

Code:

//SYSIN DD *                                         
  OPTION COPY                                         
  INCLUDE COND=(1,291,SS,EQ,C'.COM')                 
  INREC IFTHEN=(WHEN=(1,2,BI,LT,291),OVERLAY=(291:X))
/*                                                   
                                                     



Error:

Code:

ICE906I 1 ST=BELOW,SR=110142,RC=0                                         
ICE907I 1 ST=BELOW,SA=56872,NF=1,LF=56872,SF=56872                         
ICE218A 6 100 BYTE VARIABLE RECORD IS SHORTER THAN 291 BYTE MINIMUM FOR   
ICE751I 1 EF-BASE   F0-BASE   E8-I49502                                   
ICE052I 0 END OF DFSORT                                                   
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2021
Location: USA

PostPosted: Mon May 30, 2022 7:51 am
Reply with quote

Rimjhim wrote:
I first ran the job without the VLSHRT, still same error.

It is then I went through the IBM docs to see what I am missing.

Code:

//SYSIN DD *                                         
  OPTION COPY                                         
  INCLUDE COND=(1,291,SS,EQ,C'.COM')                 
  INREC IFTHEN=(WHEN=(1,2,BI,LT,291),OVERLAY=(291:X))
/*                                                   
                                                     



Error:

Code:

ICE906I 1 ST=BELOW,SR=110142,RC=0                                         
ICE907I 1 ST=BELOW,SA=56872,NF=1,LF=56872,SF=56872                         
ICE218A 6 100 BYTE VARIABLE RECORD IS SHORTER THAN 291 BYTE MINIMUM FOR   
ICE751I 1 EF-BASE   F0-BASE   E8-I49502                                   
ICE052I 0 END OF DFSORT                                                   

Please, read the previous responses more carefully.
More than one people have provided you with good hints, but you continue ignoring any answer.
Back to top
View user's profile Send private message
Rimjhim

New User


Joined: 18 May 2022
Posts: 12
Location: India

PostPosted: Mon May 30, 2022 8:08 am
Reply with quote

Apologies. It worked. icon_smile.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
No new posts Data set Rec-Cnt and Byte-Cnt Testing & Performance 2
Search our Forums:

Back to Top