‎2007 Sep 25 12:37 PM
Hi All,
Curretly i am working with ECC6.0 version and getting some syntax errors when i copy an existing program from version 4.6C. The problem is like in 4.6C version i am declaring a variable DATA:c_tab TYPE x VALUE '09' for tab delimit and using in CONCATENATE statement like
CONCATENATE field1 c_tab
field2 c_tab
-
-
into v_line1.
But when i am using the same in ECC6 then getting syntax error like
"C_TAB" must be a character-type data object (data type C, N, D, T or STRING).
Could you please do help on this.
Cheers,
Bujji.
‎2007 Sep 25 12:40 PM
well the concatenate statement works only for character type data-types.
make a character variable and put in your value to it. thne use the char field in your concantenate.
‎2007 Sep 25 12:52 PM
Hi Bujji,
in ECC6.0 you should use the prededined attributes of class CL_ABAP_CHAR_UTILITIES.
You can concatenate ... CL_ABAP_CHAR_UTILITIES=>HORIZONTAL_TAB ... INTO ....
I think you won't need anything else except
CL_ABAP_CHAR_UTILITIES=>NEWLINE
CL_ABAP_CHAR_UTILITIES=>VERTICAL_TAB
CL_ABAP_CHAR_UTILITIES=>HORIZONTAL_TAB
CL_ABAP_CHAR_UTILITIES=>FORM_FEED
CL_ABAP_CHAR_UTILITIES=>CR_LF
These atrributes will have the correct character size according to your system. Note:
ECC6.0 runs with unicode, in unicode the characters are represented by two bytes.
CONCATENATE in ECC6.0 wotks with characters only.
Regards,
Clemens
‎2007 Sep 25 1:37 PM
Hi Bujji,
As ECC 6.0 is Unicode compatible, you are getting the error. you can execute the program by disabling the unicode check.
In Abap editor menu bar
GOTO -> Atributes -> uncheck the unicode checks active.
This will help you in getting the desired output.