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
 

 

Convert the hexadecimal data into decimal format

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
zulfukharali

New User


Joined: 11 May 2006
Posts: 12

PostPosted: Sat Jul 21, 2007 4:34 am    Post subject: Convert the hexadecimal data into decimal format
Reply with quote

Hi,
I need to convert the hexadecimal data into decimal format.
When I tried the routine X2D it is throwing "INCORRECT CALL TO ROUTINE". The command I issued is X2D(substr(input_1.i,111,4))

When I use the routine C2D it is working for some records. When there is a overflow it is resulting in the error. For example, It is working for low value data's. I meant var=C2D(X'00003FB5') gives 16309 as the outcome. When the data goes as var=C2D(X'E9F35E03') it is resulting in the error. var is 10 byte field.

How to make a variable in double or float format? Please let me know how to interpret the 4 bytes of hexadecimal data into decimal.

Thanks in advance
ZA
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Sat Jul 21, 2007 1:11 pm    Post subject:
Reply with quote

Look at NUMERIC in the manual
Back to top
View user's profile Send private message
zulfukharali

New User


Joined: 11 May 2006
Posts: 12

PostPosted: Mon Jul 23, 2007 9:57 pm    Post subject: Re: Convert the hexadecimal data into decimal format
Reply with quote

Thanks expat. It worked out by changing the NUMERIC DIGITS 10.

Regards,
Zulfukhar
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts copying data without knowing location arunsoods DFSORT/ICETOOL 6 Thu Jul 20, 2017 1:03 pm
This topic is locked: you cannot edit posts or make replies. Fetching data from BAI File arunsoods JCL & VSAM 1 Wed Jul 19, 2017 4:28 pm
No new posts Loading data to table gives wrong for... Raghu navaikulam DB2 18 Thu Jul 13, 2017 2:11 pm
No new posts Convert CLIST to REXX cvnlynn CLIST & REXX 12 Tue Jun 27, 2017 2:06 am
No new posts SQL - select data available in index Nileshkul DB2 3 Mon Jun 26, 2017 1:30 am


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