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
 

 

BI,TO=ZD Changing Values

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

New User


Joined: 17 Jul 2017
Posts: 1
Location: NW Arkansas

PostPosted: Tue Jul 25, 2017 12:12 am    Post subject: BI,TO=ZD Changing Values
Reply with quote

First time poster here, long time stalker.

Ive got a unsigned comp field (FIELD3) that Im converting to ZD but it is changing the value on the output file and I cant figure out why. Ive ran it both as a FI & BI input and same result. What am I missing here? Ive got several other columns where Im doing a similar conversion and not seeing this occurrence. Thanks in advance.

Input below.
FIELD1,1,2,CH
FIELD2,3,2,CH
FIELD3,5,4,BI
FIELD4,9,4,BI
etc...

BUILD=(FIELD1,
FIELD2,
FIELD3,TO=ZD,LENGTH=9,
FIELD4,TO=ZD,LENGTH=9,
ETC...


The decimal value of X'008D4A61' is 9259617.

OUTFIL FNAMES=F1,INCLUDE=(138,2,FI,EQ,2,AND,136,2,FI,EQ,1),BUILD=(*
1,2,3,2,5,4,FI,TO=ZD,LENGTH=9,141,2,FI,TO=ZD,LENGTH=3,9,*


Code:

----+----1----+----2-
*********************
US01 ý¢/   aDC   €ST2
EEFF08460018CC0019EEF
42010DA1007143009F232
*********************



Output is changed to 9259616

Code:

----+----1----+-
****************
US01009259616092
****************
Back to top
View user's profile Send private message

Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8132
Location: East Dubuque, Illinois, USA

PostPosted: Tue Jul 25, 2017 12:49 am    Post subject: Reply to: BI,TO=ZD Changing Values
Reply with quote

I just ran a BUILD=(1,4,FI,TO=ZD,LENGTH=9) on the value X'008D4A61' in DFSORT and got the output of 009259617, so most likely something in the code you did not post is overlaying the last digit. Try running only that one conversion and see what value is output.
Back to top
View user's profile Send private message
sergeyken

Active User


Joined: 29 Apr 2008
Posts: 128
Location: Maryland

PostPosted: Thu Jul 27, 2017 1:48 am    Post subject: Re: BI,TO=ZD Changing Values
Reply with quote

Tyler Dunbar wrote:
First time poster here, long time stalker.

In your example the input record must have the length 12, while output to be 22 bytes long.
The data shown have length 21, and 16 bytes instead.
Please verify all your fields offset/size, and clarify this issue.

BTW, "BI,4" stands for signed binary, not for unsigned comp
Back to top
View user's profile Send private message
magesh23586

Active User


Joined: 06 Jul 2009
Posts: 170
Location: Chennai

PostPosted: Thu Jul 27, 2017 1:56 am    Post subject: Reply to: BI,TO=ZD Changing Values
Reply with quote

sergeyken wrote:

BTW, "BI,4" stands for signed binary, not for unsigned comp


As per dfsort programming guide

Format code BI is Unsigned binary.
Back to top
View user's profile Send private message
sergeyken

Active User


Joined: 29 Apr 2008
Posts: 128
Location: Maryland

PostPosted: Thu Jul 27, 2017 2:09 am    Post subject: Re: Reply to: BI,TO=ZD Changing Values
Reply with quote

magesh23586 wrote:
sergeyken wrote:

BTW, "BI,4" stands for signed binary, not for unsigned comp


As per dfsort programming guide

Format code BI is Unsigned binary.

I'm sorry, you're right. I messed those BI/FI abbreviations.
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 Changing sort Card Dynamically vickey_dw DFSORT/ICETOOL 3 Sat Aug 19, 2017 2:33 pm
No new posts Sorting of hex values Saurabh_mi DFSORT/ICETOOL 11 Thu May 25, 2017 3:49 pm
No new posts Replace values in the input data Vikas Maharnawar DFSORT/ICETOOL 10 Thu May 11, 2017 2:18 pm
No new posts Compare two files and subtract values ameetmund DFSORT/ICETOOL 7 Fri Mar 31, 2017 3:35 pm
No new posts Changing of LRECL of a file abdulrafi DFSORT/ICETOOL 2 Fri Mar 24, 2017 3:25 pm


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