‎2008 Mar 26 10:29 PM
Hi all,
I am using select option for MARA-MATNR. I am trying to fetch materials from MARA by entering a range like ABC5 to ABC20. Though ABC5 is less than ABC20, the program is throwing an error stating "lower limit is greater than higher limit".
Is there any way to eliminate this error? Same error I am getting with MARA table for same selection. Please guide me.
Regards,
Suresh.
‎2008 Mar 26 10:40 PM
Hi,
Since MATNR is of type CHAR, it just does a character comparision for your data
ABC5 and ABC20
The first three characters are same but 4th character '5' is greater than '2' hence the error.
Try creating a type with NUMC and use it to create your select option. I think it might solve your problem.
Regards,
Raj
‎2008 Mar 26 11:01 PM
Hi, type n will accept only numbers, not characters. The system is throwing error "enter a numeric value".
Regards,
Suresh.
‎2008 Mar 27 12:32 AM
Hi Suresh,
Two ways to remove this error
Search as ABC05 to ABC20
OR
Use NUMC (not numeric) as said above. NUMC can have number + character.
Option 1 is recommended as it is the standard way of doing.
Regards,
Atish
‎2008 Mar 27 12:50 AM
Hi Suresh,
Did you try creating a variable of type NUMC? It should accept both numbers and characters.
DATA: VAR1(10) TYPE N.
Regards,
Raj