Skip to Content
0
Former Member
Dec 13, 2006 at 06:31 PM

Transfer an internal table with non char data type to an application server

128 Views

Here is a part of my code. lv_string variable was type string initially but i got an error Not mutually convertible in a Unicode Program. I changed it to type ty_afko. Now the program works but the data it puts out has just a bunch of #####. I cannot make all value in the internal table type char because then my select statement is giving errors.. Please help...

Type: BEGIN OF ty_afko,

rsnum LIKE afko-rsnum, " Number of reservation

aprio LIKE afko-aprio, " Order Priority

maufnr LIKE afko-maufnr, " Number of superior order

lead_aufnr LIKE afko-lead_aufnr, " Leading order in current processing

END OF ty_afko.

data: gt_afko TYPE STANDARD TABLE OF ty_afko INITIAL SIZE 0,

wa_afko TYPE ty_afko,

select rsnum aprio maufnr lead_aufnr

from afko into table gt_afko.

IF gv_error = 'X'.

EXIT.

ELSE.

<b>DATA: Lv_string type ty_afko.</b>

loop at gt_afko into wa_afko.

clear lv_string.

<b> move wa_afko to lv_string.</b>

perform f_transfer_dataset using gc_f_afko lv_string changing gv_error.

endloop.

endif.

FORM f_transfer_dataset USING p_file

p_data

CHANGING p_error TYPE c.

Data: lv_file(25) type c.

CONCATENATE gc_path p_file INTO lv_file.

TRANSFER p_data TO lv_file.

ENDFORM. "F_TRANSFER_DATASET