‎2009 May 20 8:56 AM
DESCRIBE FIELD MAKT-MATNR LENGTH MNR_LNG .
that line off code gives me an error message:
In Unicode, DESCRIBE LENGTH can only be used with the IN BYTE MODE or IN CHARACTER MODE addition.
can anyone else provide me an explanation and solution..thanks
‎2009 May 20 9:28 AM
Hi,
just try like this, I had check it and it is not throwing any error.
{ DESCRIBE FIELD MAKT-MATNR LENGTH MNR_LNG in byte mode. }
Regards,
Ramesh.
‎2009 May 20 9:02 AM
Hi
see the below example.
DATA: text TYPE c LENGTH 1,
blen TYPE i,
clen TYPE i,
bytes TYPE i.
DESCRIBE FIELD text LENGTH blen IN BYTE MODE.
i used this code works fine. Try this one.
Rgds,
Kiran
‎2009 May 20 9:04 AM
do like this...
DESCRIBE FIELD MAKT-MATNR LENGTH MNR_LNG in CHARACTER MODE.
Try F1...
If u r not able to find answer Search SDN before u post...
Edited by: Veeranji Reddy on May 20, 2009 1:35 PM
‎2009 May 20 9:04 AM
Well, the solution would be to add IN CHARACTER MODE.
F1 help on DESCRIBE.
‎2009 May 20 9:15 AM
i've did exactly what you've told..
same error still occurs..
‎2009 May 20 9:05 AM
Hello,
You want to have the length of the field MAKT-MATNR. Then you can use the function STRLEN.
DATA:
MNR_LNG TYPE I.
MNR_LNG = STRLEN(MAKT-MATNR).Else as suggested you have to use the addition IN CHARACTER MODE with DESCRIBE FIELD.
Depends on your requirement.
Hope this helps !!
BR,
Suhas
‎2009 May 20 9:25 AM
hi suhas,
does the STRLEN function has the same outcome as DESCRIBE FIELD?
if it does, i can use STRLEN as a replacement instead.
thanks
soo hing
‎2009 May 20 9:28 AM
Hi,
just try like this, I had check it and it is not throwing any error.
{ DESCRIBE FIELD MAKT-MATNR LENGTH MNR_LNG in byte mode. }
Regards,
Ramesh.
‎2009 May 20 9:35 AM
Try this statement,i think it will works
DESCRIBE FIELD MAKT-MATNR LENGTH MNR_LNG IN BYTE MODE.
‎2010 Feb 05 9:43 PM
Hi,
When you are using descirbe statement u have to user either charcter mode or binary mode in Unicode.