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
 

 

SYNCSORT: OUTREC Numeric edited field

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
dipakgoyal
Warnings : 1

New User


Joined: 02 Aug 2007
Posts: 18
Location: Kolkata

PostPosted: Mon Jan 10, 2011 4:54 pm    Post subject: SYNCSORT: OUTREC Numeric edited field
Reply with quote

I have an input-file, with a field
IN-AMT PIC S9(05)V999 SIGN IS LEADING SEPARATE CHARACTER.

The first 2 values are:
+00112.738
+00024.119

When I used the SYNCSORT to download it to a output file, using:

OUTREC FIELDS=(001:197,08,ZD,
010:C';',

The output I get is:

112730-;
24110-;

i.e.
1. Decimal is not printed
2. Negative sign coming in the end
3. LSB is truncated


Please note that increasing the input-field length , i.e using
OUTREC FIELDS=(001:197,09,ZD,
results in S0C7

Is there any way, apart from using EDIT=TTT.TTT
using which I can get the same output as input
like the way we use ZD,M4?
Back to top
View user's profile Send private message

nareshdacha

New User


Joined: 12 Jan 2010
Posts: 66
Location: US

PostPosted: Mon Jan 10, 2011 6:31 pm    Post subject: Reply to: SYNCSORT: OUTREC Numeric edited field
Reply with quote

Try this out.....


SORT FIELDS=COPY
OUTREC FIELDS=(1:1,10,SFF,EDIT=(STTTTT.TTT),SIGNS=(+,-))
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2181
Location: @my desk

PostPosted: Tue Jan 11, 2011 11:30 am    Post subject:
Reply with quote

nareshdacha,

The field under question occupies ONLY 9 bytes and NOT 10 bytes as in your post.

dipakgoyal,

I believe this would work for you.
Code:
OUTREC FIELDS=(1:197,9,ZD,EDIT=(STTTTT.TTT),SIGNS=(+,-))
Back to top
View user's profile Send private message
dipakgoyal
Warnings : 1

New User


Joined: 02 Aug 2007
Posts: 18
Location: Kolkata

PostPosted: Thu Jan 13, 2011 4:10 pm    Post subject:
Reply with quote

Thanks Arun
It solves the purpose
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2181
Location: @my desk

PostPosted: Fri Jan 14, 2011 11:05 pm    Post subject:
Reply with quote

Youre welcome. 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    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SYNCSORT SEQNUM and FI fields. nartcr SYNCSORT 5 Sat Jan 21, 2017 4:02 am
No new posts INVALID FIELD OR CONSTANT IN SORTOF ?? Ron Klop DFSORT/ICETOOL 8 Wed Jan 11, 2017 3:44 pm
No new posts Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
No new posts Performing arithmetic on input field zh_lad DFSORT/ICETOOL 31 Tue Dec 06, 2016 8:04 pm
No new posts syncsort: copy lines after the keyword shreya19 SYNCSORT 7 Fri Dec 02, 2016 9:47 am


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