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
 

 

Alphanumeric to packed decimal

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CA Products
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    Post subject: Alphanumeric to packed decimal
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    Post subject: Re: Alphanumeric to packed decimal
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

Site Director


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

PostPosted: Fri Nov 02, 2007 1:54 am    Post subject:
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    IBMMAINFRAMES.com Support Forums -> CA Products All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. How to move a long alphanumeric data ... lind sh COBOL Programming 8 Mon Dec 05, 2016 7:51 pm
No new posts Comparing Decimal and CHAR columns rakesh17684 DB2 7 Thu Oct 20, 2016 2:33 am
This topic is locked: you cannot edit posts or make replies. Alphanumeric to Numeric move on UNIX mistah kurtz COBOL Programming 16 Wed Jul 27, 2016 8:47 pm
No new posts Convert Decimal to hexadecimal Steve Ironmonger DFSORT/ICETOOL 5 Fri May 27, 2016 4:19 pm
This topic is locked: you cannot edit posts or make replies. JCL to convert float decimal into rea... polymathtarun JCL & VSAM 3 Sun May 15, 2016 9:57 pm


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