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

Author Message
sathish_rathinam

New User

Joined: 22 Aug 2005
Posts: 59
Location: india

 Posted: Wed Jun 25, 2008 11:36 am    Post subject: How to check a Decimal value for NUMERIC Is there any function for checking a decimal value for NUMERIC condition. I tried checking 99.99 value is NUMERIC, but i got the result showing 99.99 in not a NUMERIC. How can we process this without a INSPECT statement.

vasanthkumarhb

Active User

Joined: 06 Sep 2007
Posts: 276
Location: Bang,iflex

Posted: Wed Jun 25, 2008 12:19 pm    Post subject:

Hi,

you can make use of EVALUATE function.

like

 Code: EVALUATE TRUE     WHEN VARIABLE = 0000.00 THRU 9999.99        STATEMENT        STATEMENT        STATEMENT     WHEN OTHER        DISPLAY ' CHECK CONDITION FAILED'        END-EVALUATE

This will not work in all cases.
sasikaran

New User

Joined: 24 Jun 2008
Posts: 3
Location: chennai

 Posted: Wed Jun 25, 2008 12:49 pm    Post subject: Reply to: How to check a Decimal value for NUMERIC We cant check the numeric for decimal values..U can check for the filed from which the 99.99 is moved.
sasikaran

New User

Joined: 24 Jun 2008
Posts: 3
Location: chennai

 Posted: Wed Jun 25, 2008 2:48 pm    Post subject: Reply to: How to check a Decimal value for NUMERIC The other option is to MOVE the 99.99 to a working storage variable of 99v99 and check Numeric for this Working storage field. Hope this helps.
 All times are GMT + 6 Hours
 Page 1 of 1

Search our Forum:

 Topic Author Forum Replies Posted Similar Topics GDG gen check using REXX raghuraman123 CLIST & REXX 6 Wed Apr 18, 2018 9:18 pm Sort numeric fields with trailing spaces sancraig16 SYNCSORT 7 Tue Apr 03, 2018 1:21 am How syntax check at Bind time is diff... Poha Eater DB2 5 Wed Mar 21, 2018 9:16 pm How to group and sum the decimal value sakrat DFSORT/ICETOOL 2 Tue Mar 06, 2018 9:13 pm Moving a COMP-3 Variable to a Numeric... ajayachander COBOL Programming 2 Thu Dec 14, 2017 5:46 pm

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