IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Alphanumeric to packed decimal


IBM Mainframe Forums -> CA Products
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
jassi123

New User


Joined: 27 Mar 2007
Posts: 2
Location: India

PostPosted: Fri Nov 02, 2007 12:40 am
Reply with quote

How to convert an alphanumeric value to packed decimal. The alphanumeric variable is holding number only and no alphabets.
For eg. alphanumeric varible has '12345' as the value. Now the requirement is just to change the type to packed decimal.
Back to top
View user's profile Send private message
jassi123

New User


Joined: 27 Mar 2007
Posts: 2
Location: India

PostPosted: Fri Nov 02, 2007 12:50 am
Reply with quote

Forgot to mention earlier... this is to be done in a eztrieve program...
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Fri Nov 02, 2007 1:54 am
Reply with quote

Hello jassi and welcome to the forums,

If you are completely sure the field will always contain numerics only, you could redefine it as a zoned decimal number and move the zd field to the comp-3 field.

If the field ever contained an invalid value, you would have to deal with an abend.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CA Products

 


Similar Topics
Topic Forum Replies
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts PD not working for unsigned packed JO... DFSORT/ICETOOL 5
No new posts Def PD not working for unsigned packe... JCL & VSAM 3
No new posts Need Help with Packed Decimal Signs DFSORT/ICETOOL 4
No new posts Select a DB2 value in a specific deci... DB2 4
Search our Forums:

Back to Top