‎2009 Mar 11 10:35 PM
HI after upgrade iam using an include in my program
where iam getting and syntax error stating
In Unicode, DESCRIBE LENGTH can only be used with the IN BYTE MODE or
IN CHARACTER MODE addition.
FOR THE BELOW CODE IN THE INCLUDE.
DATA: L_LENGTH TYPE I.
DESCRIBE FIELD L_MSGTX LENGTH L_LENGTH.
‎2009 Mar 12 2:45 AM
4.7 and above Ver:
describe field pdf_data length v_length in byte mode.
Byte Mode is an addition in Unicode system (4.7).Byte mode will generally give the length in bytes
1 Character holds one byte and an integer is of 4 bytes.
There is anther addition also character mode which is used for flat and character types.
4.6b Ver:
describe field pdf_data length v_length.
It is for non unicode system.this will not work in unicode systems.(i.e4.7).
It will give you also lenght in bytes.
Only difference is Unicode and Non-Unicode system..
Hope this will resolve your query.
Regards,
Gurpreet
‎2009 Mar 11 10:53 PM
Look at the abap documentation, and tell us what you don't understand. Also read [abap & unicode chapter in sap library|http://help.sap.com/saphelp_nw2004s/helpdata/en/62/3f2cadb35311d5993800508b6b8b11/frameset.htm]
‎2009 Mar 12 2:45 AM
4.7 and above Ver:
describe field pdf_data length v_length in byte mode.
Byte Mode is an addition in Unicode system (4.7).Byte mode will generally give the length in bytes
1 Character holds one byte and an integer is of 4 bytes.
There is anther addition also character mode which is used for flat and character types.
4.6b Ver:
describe field pdf_data length v_length.
It is for non unicode system.this will not work in unicode systems.(i.e4.7).
It will give you also lenght in bytes.
Only difference is Unicode and Non-Unicode system..
Hope this will resolve your query.
Regards,
Gurpreet
‎2009 Mar 12 3:04 AM
Hi
the addition IN BYTE MODE determines the length of the data object <dobj> in bytes
the addition IN CHARACTER MODE determines the length of the data object <dobj> in characters
Note: When using IN CHARACTER MODE, the data type of dobj must be flat and character-type. You can only specify IN BYTE MODE for deep data types
DATA: text TYPE c LENGTH 1,
blen TYPE i,
clen TYPE i,
bytes TYPE i.
DESCRIBE FIELD text: LENGTH blen IN BYTE MODE,
LENGTH clen IN CHARACTER MODE.
bytes = blen / clen.