Operating System - OpenVMS
1752595 Members
4603 Online
108788 Solutions
New Discussion юеВ

Re: Evaluating COBOL expression gives unexpected result

 
SOLVED
Go to solution
Homer Shoemaker
Frequent Advisor

Re: Evaluating COBOL expression gives unexpected result

Thanks Dennis. Interesting. I didn't know that. I've never had occasion to use a level 66 item. I'll look into it.

Richard J Maher
Trusted Contributor

Re: Evaluating COBOL expression gives unexpected result

Hi Homer,

Don't forget IS NUMERIC and INSPECT REPLACEING ALL.

To expect the compiler to produce more than a compile-time error when performing some sort of Java casting or generics check would, IMHO, be a worthless exercise.

You're just mapping a chunck of memory, and COBOL, like most other 3GLS, let's you describe it however you like. Works for me.

Cheers Richard Maher
Homer Shoemaker
Frequent Advisor

Re: Evaluating COBOL expression gives unexpected result

Thanks Richard. I considered the IS NOT NUMERIC solution after I had already moved on to the next section of code, but I'll probably go back. That's probably a better solution than checking for spaces.