To assign zero to new comp-3 field in existing record



IBM's flagship sort product DFSORT for sorting, merging, copying, data manipulation and reporting. Includes ICETOOL and ICEGENER

To assign zero to new comp-3 field in existing record

Postby haribabu80 » Fri Nov 27, 2009 2:21 pm

I have introduced a new field in existing file and defined as comp-3. When i give this file has input, it is abended with soc7. Now i want to replace the filed spaces with zeros. Can anyone pls help me?

Then new field start from 380 to 384.
haribabu80
 
Posts: 1
Joined: Fri Nov 27, 2009 2:16 pm
Has thanked: 0 time
Been thanked: 0 time

Re: To assign zero to new comp-3 field in existing record

Postby Frank Yaeger » Sat Nov 28, 2009 6:07 am

To replace spaces in 380-384 with a valid PL5'0' field (COMP-3), you can use these DFSORT statements:

   INREC IFTHEN=(WHEN=(380,5,CH,EQ,C' '),OVERLAY=(380:+0,TO=PD,LENGTH=5))


To replace any non-numeric PD value in 380-384 with a valid PL5'0' field, you can use these DFSORT statements:

   INREC IFTHEN=(WHEN=(380,5,PD,NE,NUM),OVERLAY=(380:+0,TO=PD,LENGTH=5))
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
User avatar
Frank Yaeger
Global moderator
 
Posts: 1079
Joined: Sat Jun 09, 2007 8:44 pm
Has thanked: 0 time
Been thanked: 15 times


Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post