Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist 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 File Aid tool to compare numeric data balaji81_k Compuware & Other Tools 2 Tue Sep 26, 2017 3:35 am
No new posts Remove leading spaces from numeric field rexx77 SYNCSORT 6 Wed Sep 06, 2017 2:15 am
No new posts Return a Non Numeric value from REXX Learncoholic CLIST & REXX 3 Fri Sep 01, 2017 8:33 pm
No new posts Select numeric portion from CHAR data... balaji81_k DB2 6 Sat Aug 19, 2017 1:51 am
No new posts Validate if a Value from the file is ... balacsv2 COBOL Programming 8 Mon Jun 19, 2017 11:52 pm

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