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
 

 

Converting from Numeric to COMP-3 in job

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
bhaskar_kanteti

Active User


Joined: 01 Feb 2007
Posts: 120
Location: USA

PostPosted: Thu Jul 12, 2007 8:45 pm    Post subject: Converting from Numeric to COMP-3 in job
Reply with quote

Hi,

I had a query converting NUMERIC to COMP-3.
I am copying all the data from input file to output file using icetool.
The important thing is one of the field in my input is 9(10) and the same field in my output is s9(10) comp-3. How can i convert this filed from numeric to comp-3.

This is my job:
//STEP010 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=C
//SYSPRINT DD SYSOUT=*
//*INPUT FILE
//INPUT DD DSN=INPUT.FILE,DISP=SHR
//*OUTPUT FILE
//OUTPUT DD DSN=OUTPUT.FILE,
// DISP=(,CATLG,DELETE),SPACE=(CYL,(500,500),RLSE),
// RECFM=FB,LRECL=563,
//TOOLIN DD *
COPY FROM(INPUT) TO(OUTPUT) USING(CTL1)
/*

//CTL1CNTL DD *
OUTFIL FNAMES=OUTPUT,REMOVECC,
OUTREC=(1:1,7,8:40,3,11:14,26,37:43,486,523:539,13, -
536:552,10,FI,TO=PD,LENGTH=6, -
542:562,6,548:568,10,FI,TO=PD,LENGTH=6, -
554:538,1,555:529,9)
/*

The bolded part is the way i tried to convert from numeric to somp-3.
But it is giving error as follows:
Code:
  OUTFIL FNAMES=OUTPUT,REMOVECC,                                 
  OUTREC=(1:1,7,8:40,3,11:14,26,37:43,486,523:539,13, -           
          536:552,10,FI,TO=PD,LENGTH=6, -                         
                     ?                                             
REFORMATTING FIELD ERROR                                           
          542:562,6,548:568,10,FI,TO=PD,LENGTH=6, -               
          ?                                                       
SYNTAX ERROR                                                       
          554:538,1,555:529,9)                                     
          ?                                                       
SYNTAX ERROR                                                       
END OF STATEMENTS FROM CTL1CNTL - PARAMETER LIST STATEMENTS FOLLOW
Back to top
View user's profile Send private message

Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Thu Jul 12, 2007 8:55 pm    Post subject:
Reply with quote

You have 552,10,FI and 568,10,ZD - the 10 is flagged because the maximum length for an FI field is 8.

But you say your input field is 9(10). That's a ZD field, not an FI field. So you should use 552,10,ZD instead of 552,10,FI and 568,10,ZD instead of 568,10,FI. The maximum length for a ZD field is 31.
Back to top
View user's profile Send private message
bhaskar_kanteti

Active User


Joined: 01 Feb 2007
Posts: 120
Location: USA

PostPosted: Fri Jul 13, 2007 4:22 pm    Post subject: Re: Converting from Numeric to COMP-3 in job
Reply with quote

Hi Frank Yaeger,

Its working.
Thank you very much.
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts Validate date and numeric fields and ... Rick Silvers DFSORT/ICETOOL 6 Thu May 11, 2017 6:51 pm
No new posts Converting decimal to numeric using I... Balaryan DFSORT/ICETOOL 4 Thu Feb 02, 2017 11:27 pm
This topic is locked: you cannot edit posts or make replies. DB2 query Using Recursion, Converting... smilewithashu2 DB2 3 Tue Jan 03, 2017 12:50 pm
No new posts Sort records based on numeric field. Alks SYNCSORT 2 Wed Oct 19, 2016 10:14 pm


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