View previous topic :: View next topic
|
Author |
Message |
sreenivasreddyg
New User
Joined: 23 Apr 2005 Posts: 39 Location: delhi
|
|
|
|
Our compiler is not supporting NUMVAL function. Is there any way, to convert Alphanumeric to COMP-3 value? |
|
Back to top |
|
|
agkshirsagar
Active Member
Joined: 27 Feb 2007 Posts: 691 Location: Earth
|
|
|
|
Do you know what non numeric charactars may be present in the alpha variable?
If only spaces and numbers are there then, using inspect replace spaces by zeros and move that to numeric variable. If it is more complex situation then we need to here more from you. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Please post the source statement(s) and compiler output that shows the error(s). Also please post the info in the compiled output that shows which compiler you are using.
Then, please post some sample data and what you want done with it. The data needs to show the different "patterns" your input might contain. |
|
Back to top |
|
|
Raphael Bacay
New User
Joined: 04 May 2007 Posts: 58 Location: Manila, Philippines
|
|
|
|
Hello,
Maybe you can try the following:
IF ALPHA-NUMERIC-VAR IS NUMERIC
MOVE ALPHA-NUMERIC-VAR TO COMP3-VAR
END-IF
If this does not work try...
IF ALPHA-NUMERIC-VAR IS NUMERIC
MOVE ALPHA-NUMERIC-VAR TO NUMERIC-VAR
MOVE NUMERIC-VAR TO COMP3-VAR
END-IF |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
As requested last week,
Quote: |
Please post the source statement(s) and compiler output that shows the error(s). Also please post the info in the compiled output that shows which compiler you are using.
Then, please post some sample data and what you want done with it. The data needs to show the different "patterns" your input might contain.
|
Please keep in mind that many of us have written code to check for numeric long before there was a NUMVAL function available.
When you post your specifics, we can offer better suggestions. |
|
Back to top |
|
|
|