Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

FM FOR NUMERIC CHECK

Hello All,

Is there any FM present to check if a value is numeric and does not contain any alphanumeric or character values?

Thanks,

Tags:
replied

If you are using a character field and do not want to compinsate for the SPACE in the field. You can do something like this as well.


report zrich_0001 .


data: field(10) type c value '1%56539'.
data: length type i.


length = strlen( field ).

if field(length) co '1234567890'.
  write:/ 'This is a number'.
else.
  write:/ 'This is not a number'.
endif.

Regards,

Rich Heilman

1 View this answer in context

Helpful Answer

by
Not what you were looking for? View more on this topic or Ask a question