Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Forum Index
 
Register
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Display Signed ZD field

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

Active User


Joined: 05 Dec 2006
Posts: 168
Location: Seattle, WA

PostPosted: Thu Feb 28, 2019 1:17 am    Post subject: Display Signed ZD field
Reply with quote

I've read the DFSORT manual and tried a variety of edit fields, but just can't get this to work.

I have a field that is one byte and is X'JD'. I want to use the OUTFIL OUTREC parameters to display this as '1-'.

I have tried the Mx edits and custom edits and can't get past this error. I either get U126 or U007.

Here are a couple of samples I've tried:

595:509,01,ZD,EDIT=(T),SIGNS(+,-))

595:509,01,PD,EDIT=(M1))

Does anyone have any ideas on this?
Back to top
View user's profile Send private message

Arun Raj

Moderator


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

PostPosted: Thu Feb 28, 2019 1:39 am    Post subject:
Reply with quote

Quote:
I have a field that is one byte and is X'JD'
X'JD' appears to be invalid. What do you see in that position with HEX-ON?
Back to top
View user's profile Send private message
socker_dad

Active User


Joined: 05 Dec 2006
Posts: 168
Location: Seattle, WA

PostPosted: Thu Feb 28, 2019 1:44 am    Post subject:
Reply with quote

Crap.

It's X'D1'.

It's been a long day. :-(
Back to top
View user's profile Send private message
Arun Raj

Moderator


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

PostPosted: Thu Feb 28, 2019 1:55 am    Post subject:
Reply with quote

Code:
509,01,ZD,EDIT=(TS),SIGNS(,,+,-)
for a TRAILING sign worked good for me. If you still get an error, post the error message from your SYSOUT.
Back to top
View user's profile Send private message
socker_dad

Active User


Joined: 05 Dec 2006
Posts: 168
Location: Seattle, WA

PostPosted: Thu Feb 28, 2019 2:14 am    Post subject:
Reply with quote

Not yet.....

Code:

594:509,01,ZD,EDIT=(TS),SIGNS(,,+,-))   

ICE126A 9 INCONSISTENT REFORMATTING FOR SORTOUT : REASON CODE 04, IFTHEN 0 
ICE751I 0 C5-BASE   C6-BASE   C7-BASE   C8-BASE   E9-I48763 E7-I49502       
ICE052I 3 END OF DFSORT                                                     
Back to top
View user's profile Send private message
Arun Raj

Moderator


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

PostPosted: Thu Feb 28, 2019 2:21 am    Post subject:
Reply with quote

Code:
ICE126A 9 INCONSISTENT REFORMATTING FOR SORTOUT : REASON CODE 04, IFTHEN 0
Unless you show the complete SYSOUT/Control statements, including the IFTHEN, hard to guess.
Back to top
View user's profile Send private message
socker_dad

Active User


Joined: 05 Dec 2006
Posts: 168
Location: Seattle, WA

PostPosted: Thu Feb 28, 2019 2:28 am    Post subject:
Reply with quote

Found the problem. Thanks for your help and patience!
Back to top
View user's profile Send private message
Arun Raj

Moderator


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

PostPosted: Thu Feb 28, 2019 2:41 am    Post subject:
Reply with quote

Great! Do you mind posting what you found, for the benefit of others.
Back to top
View user's profile Send private message
steve-myers

Active Member


Joined: 30 Nov 2013
Posts: 750
Location: The Universe

PostPosted: Thu Mar 07, 2019 12:32 pm    Post subject:
Reply with quote

A zoned decimal X'D1' is -1 (or perhaps 1-, depending on whether you want a leading or trailing sign. See the discussion on decimal signs in this link.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2220
Location: Hampshire, UK

PostPosted: Thu Mar 07, 2019 4:01 pm    Post subject: Reply to: Display Signed ZD field
Reply with quote

I thought x'1D' was -1 (or 1-)? D1 is alpha 'J' - hence the confusion up top?
Back to top
View user's profile Send private message
steve-myers

Active Member


Joined: 30 Nov 2013
Posts: 750
Location: The Universe

PostPosted: Thu Mar 07, 2019 7:10 pm    Post subject:
Reply with quote

A 1 byte packed decimal X'1D' is -1 as is a 1 byte zoned decimal X'D1'
Back to top
View user's profile Send private message
socker_dad

Active User


Joined: 05 Dec 2006
Posts: 168
Location: Seattle, WA

PostPosted: Thu Mar 07, 2019 9:41 pm    Post subject:
Reply with quote

Well it turns out it wasn't the packed sign that was the problem: it was that the column assignment overlaid another field definition. I assumed (dangerous, I know) that the problem was with the edit mask, since that was the first time I had used one in DFSort.

Sigh, I wish this installation had SyncSort rather then DFSort. SyncSort messages were much easier to understand.
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 SECTION BASED ON FIELD speermb DFSORT/ICETOOL 10 Mon Jun 17, 2019 9:41 pm
No new posts Send text at cursor position on an IS... Domenic Ailati CLIST & REXX 10 Sun Jun 02, 2019 7:34 am
No new posts Display current IMS region on an On-l... Time2Live IMS DB/DC 1 Fri May 03, 2019 1:59 am
No new posts Convert alpha numeric to signed digits Balu5491 COBOL Programming 4 Mon Feb 25, 2019 10:39 pm
No new posts DB2 Timestamp field weird behaviour. rizwanaccy DB2 7 Wed Dec 26, 2018 4:33 pm

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