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
 

 

difference beween alphanumeric and numeric in cobol

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
apsar.kogatam
Warnings : 1

New User


Joined: 27 Jun 2008
Posts: 33
Location: CHENNAI

PostPosted: Wed Mar 03, 2010 12:00 pm    Post subject: difference beween alphanumeric and numeric in cobol
Reply with quote

Hi,

Plz explain me the difference beween alphanumeric and numeric in cobol with a sample example.

Can we move alphanumeric(x) to numeric(9) and also vice versa.
Back to top
View user's profile Send private message

Binop B

Active User


Joined: 18 Jun 2009
Posts: 407
Location: Nashville, TN

PostPosted: Wed Mar 03, 2010 2:22 pm    Post subject:
Reply with quote

Hi Apsar
Quote:
Plz explain me the difference beween alphanumeric and numeric in cobol with a sample example.
Why dont you have a look into the manuals (link available on the top of this page) and let us know if you didn't find your answer..

Quote:
Can we move alphanumeric(x) to numeric(9) and also vice versa.
What happened when you tried it ? or what is being said in the manuals ?

Both your questions are pretty basic stuff which you can understand just by having a look into the manuals or testing them on your own ...
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2150
Location: At my coffee table

PostPosted: Wed Mar 03, 2010 6:22 pm    Post subject: Re: difference beween alphanumeric and numeric in cobol
Reply with quote

apsar.kogatam wrote:
Plz explain me the difference beween alphanumeric and numeric in cobol with a sample example.
5.3.12.3.2 Numeric items
Types of numeric items are:
Binary
Packed decimal (internal decimal)
Zoned decimal (external decimal)
National decimal (external decimal)


5.3.12.3.4 Alphanumeric items
The PICTURE character-string must consist of either of the following:
One or more occurrences of the symbol X.
Combinations of the symbols A, X, and 9. (A character-string containing all As or all 9s does not define an alphanumeric item.)
Quote:
Can we move alphanumeric(x) to numeric(9) and also vice versa.
Numeric or numeric-edited:
When the category of the sending item is alphanumeric, alphanumeric-edited, national, or national-edited, the data is moved as if the sending item were described as an unsigned integer.
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: Wed Mar 03, 2010 8:37 pm    Post subject:
Reply with quote

Hello,

If you move pic x fields to numeric fields without ensuring they are valid numerics first, you will introduce many problems - including data errors and abends . . .
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts RULES(NOEVENPACK) in cobol jackzhang75 COBOL Programming 5 Wed Mar 29, 2017 12:47 am
No new posts SQL query not working in Cobol program. CuriousMainframer COBOL Programming 14 Wed Feb 22, 2017 5:56 pm
No new posts Execute TSO ACF commands from COBOL-I... supreethi.srid TSO/ISPF 0 Tue Feb 21, 2017 5:19 pm
No new posts Mainframe Interview Questions CICS,CO... akshathan Mainframe Interview Questions 6 Thu Feb 09, 2017 6:38 pm
No new posts Converting decimal to numeric using I... Balaryan DFSORT/ICETOOL 4 Thu Feb 02, 2017 11:27 pm


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