to convert a field of s9(9) to alphanumeric



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

to convert a field of s9(9) to alphanumeric

Postby Shireesha09 » Fri May 21, 2010 6:45 pm

Hi,

I want to convert a field of s9(9) to alphanumeric and want to omit this field based on conditions.Can anyone help me in this..
The sort card i sused below.But still the field is not ommitted.

SORT FIELDS=(27,9,CH,A)
OMIT FIELD=(27,9,CH,EQ, C'666666666').
Shireesha09
 
Posts: 2
Joined: Fri May 21, 2010 6:10 pm
Has thanked: 0 time
Been thanked: 0 time

Re: to convert a field of s9(9) to alphanumeric

Postby Frank Yaeger » Fri May 21, 2010 10:39 pm

What do the values of the S9(9) field look like in hex? Do they have C signs, F signs or D signs?

What do you want the converted values to look like exactly (alphanumeric can mean a lot of things)?

You can handle the S9(9) values directly regardless of their signs by using ZD format, e.g.

    OMIT COND=(27,9,ZD,EQ,666666666)
    SORT FIELDS=(27,9,ZD,A)


If the values have C signs and you want them to be printable, you can use these DFSORT control statements to give the values F signs so they'll be printable:

    INREC OVERLAY=(27:27,9,ZD,TO=ZDF,LENGTH=9)
    OMIT COND=(27,9,CH,EQ,C'666666666')
    SORT FIELDS=(27,9,CH,A)


If the values have F signs, then you don't need to convert them as they are already alphanumeric so this will work:

    OMIT COND=(27,9,CH,EQ,C'666666666')
    SORT FIELDS=(27,9,CH,A)


If the values have D signs, those are negative, so you have to indicate what you want the output values to look like.
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 JCL

 


  • Related topics
    Replies
    Views
    Last post