Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref

Author Message
chaitanyav

New User

Joined: 13 May 2008
Posts: 3

Robert Sample

Global Moderator

Joined: 06 Jun 2008
Posts: 8233
Location: Dubuque, Iowa, USA

Posted: Thu Jan 21, 2010 6:00 pm    Post subject:

SPACE is hex '40' in EBCDIC.
Simple arithmetic tells you there are 62 characters in the EBCDIC collating sequence that are larger than LOW-VALUES and less than SPACES.

 Quote: IF WW-CADEAU > 0 OR < 0
Why not say
 Code: IF  WW-CADEAU NOT EQUAL ZERO
which makes a lot more sense than the code you have. Also note the improvement in readability that using BBcode provides.

You need to click on the manuals link at the top of the page, find the COBOL Language Reference and Application Programming Guide manuals and read them -- cover to cover. If you do so, you will find that the hex value for WW-CADEAU is x'000000000C' which is, indeed, less than SPACES (x'4040404040') and greater than LOW-VALUES (x'0000000000').

If you want the find the collating sequence characters between LOW-VALUES and SPACES yourself, Google is your friend.
dick scherrer

Site Director

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

Posted: Thu Jan 21, 2010 9:13 pm    Post subject:

Hello,

 Quote: I am confused about the values.

Part of your confusion may be due to how things are done on ASCII (Windows, UNIX) systems. In UNIX, there is a term - "working below spaces" - that means the data is most likely some kind of control character rather than user data. On those systems a SPACE is an x'20', so these values are from x'00' thru x'1F'.

If you look at the ebcdic values from x'00' - x'FF' and the ascii values for the same, there is little similarity.

Before using a "user" input value as numeric, you should make sure that it contains valid numeric data.
 All times are GMT + 6 Hours
 Page 1 of 1

Search our Forum:

 Topic Author Forum Replies Posted Similar Topics Query to compare 2 values of 1 column... Poha Eater DB2 13 Fri Mar 09, 2018 10:45 am attchmvs from rexx subroutine that re... harisukumaran CLIST & REXX 1 Fri Jan 19, 2018 5:29 am Inefficient BUILD - VB records paddin... Daniel Prosser SYNCSORT 9 Thu Dec 14, 2017 3:52 pm Extend the decimal values in DIVISION Balaryan DFSORT/ICETOOL 3 Thu Oct 05, 2017 4:05 pm Working with hex values in Filemanage... Emile Straker IBM Tools 1 Tue Sep 12, 2017 1:42 am

 © 2003-2017 IBM MAINFRAME Software Support Division
 Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us