‎2008 Apr 03 6:13 PM
hi all i have a req i need to concatenate matnr,vkorg and vtweg into a variable it should be as below.
matnr= 1234
vkorg=0400
vtweg=01
concatenated value should be 1234 0400 01.
leaving the field length as it is.
but now i am getting as 1234040001.whish is not desirable
please let me how to get the type .
<REMOVED BY MODERATOR>
Edited by: Alvaro Tejada Galindo on Apr 3, 2008 1:22 PM
‎2008 Apr 03 6:15 PM
‎2008 Apr 03 6:16 PM
data v_str type string.
concatenate matnr vkorg vtweg into v_str separated by CL_ABAP_CHAR_UTILITIES=>SPACE_STR.G@urav.
‎2008 Apr 03 6:18 PM
Hi,
this coding should work:
data result type string.
concatenate matnr vkorg vtweg into result separated by space.
Regards,
Thomas Langen
‎2008 Apr 03 6:23 PM
Use Concatenate ..separated by space..
CONCATENATE MATNR VKORG VTWEG INTO .....SEPARATED BY SPACE.
‎2008 Apr 03 6:39 PM
Hi,
You can do as below :
data : string(30) type c.
matnr= 1234
vkorg=0400
vtweg=01
concatenate matnr vkorg vtweg into string separated by space.
write : string.
Thanks,
Sriram Ponna.
‎2008 Apr 03 6:51 PM
hi check this ...here u can give the values from the db table...
tables: mara,marc,mard,vbak.
parameters: p_matnr like mara-matnr,
p_vkorg like vbak-vkorg,
p_vtweg like vbak-vtweg .
data: v_matnr like mara-matnr,
v_vkorg like vbak-vkorg,
v_vtweg like vbak-vtweg ,
v_test(50) type c.
v_matnr = p_matnr.
v_vkorg = p_vkorg .
v_vtweg = p_vtweg .
concatenate v_matnr v_vkorg v_vtweg into v_test .
write:/ v_test no-zero.
regards,
venkat.