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

Valid values for ALPHABETIC-UPPER in Cobol?


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
narendrabade

New User


Joined: 27 Jan 2011
Posts: 6
Location: Pune

PostPosted: Thu Jun 16, 2011 5:56 pm
Reply with quote

Hi,

Can someone tell me the valid set of ALPHABETIC-UPPER in cobol?

For Example: valid set for NUMERIC is : 1 2 3 4 5 6 7 8 9 0

What is set for ALPHABETIC-UPPER??


I also checked existing post regarding same but didn't find anything similar to this.

Thanks,
Narendra
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2501
Location: Atlanta, Georgia, USA

PostPosted: Thu Jun 16, 2011 6:03 pm
Reply with quote

Is this a trick question?

Letters "A" through "Z". icon_rolleyes.gif

Note that in the EBCDIC collating sequence (unlike ASCII), these values are NOT consecutive.

X'C1' --- X'C9' (A-I)

X'D1' --- X'D9' (J-R)

X'E2' --- X'E9' (S-Z)

Bill
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Thu Jun 16, 2011 6:05 pm
Reply with quote

narendrabade wrote:
Hi,

Can someone tell me the valid set of ALPHABETIC-UPPER in cobol?

For Example: valid set for NUMERIC is : 1 2 3 4 5 6 7 8 9 0

What is set for ALPHABETIC-UPPER??


I also checked existing post regarding same but didn't find anything similar to this.

Thanks,
Narendra


Have you tried looking in the COBOL Language Reference?
Back to top
View user's profile Send private message
Jose Mateo

Active User


Joined: 29 Oct 2010
Posts: 121
Location: Puerto Rico

PostPosted: Thu Jun 16, 2011 7:29 pm
Reply with quote

Good day to all!

Alphabetic-upper is a CLASS clause use in SPECIAL-NAMES. Alphabetic-upper is A thru Z and space.
Back to top
View user's profile Send private message
Dsingh29

Active User


Joined: 16 Dec 2008
Posts: 132
Location: IBM

PostPosted: Fri Jun 17, 2011 11:32 am
Reply with quote

In OS/VS COBOL, only uppercase letters and the space character were considered to be ALPHABETIC.

In Enterprise COBOL, uppercase letters, lowercase letters, and the space character are considered to be ALPHABETIC.

If your OS/VS COBOL program uses the ALPHABETIC class test, and the data tested consists of mixed uppercase and lowercase letters, there can be differences in execution results. In such cases, you can ensure identical results by substituting the Enterprise COBOL ALPHABETIC-UPPER class test for the OS/VS COBOL ALPHABETIC test.


Thats why you need to use it in SPECIAL-NAMES.
Back to top
View user's profile Send private message
Kjeld

Active User


Joined: 15 Dec 2009
Posts: 365
Location: Denmark

PostPosted: Fri Jun 17, 2011 6:49 pm
Reply with quote

You should also be aware that in some code page representations national characters and most special characters will be outside the ALPHABETIC class.
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 -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts INCLUDE OMIT COND for Multiple values... DFSORT/ICETOOL 5
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
No new posts COBOL ZOS Web Enablement Toolkit HTTP... COBOL Programming 0
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
Search our Forums:

Back to Top