on 07-11-2023 1:29 PM
Hello Experts,
I have an internal table which is of Dynamic Type created as below:
METHOD BUILD_LOG:
FIELD-SYMBOLS: <lt_tabinput> TYPE ANY TABLE.
ASSIGN (iv_tabname) TO <lt_tabinput>. "iv_taname is importing param of method.
ENDMETHOD.
above makes <lt_tabinput> like GT_GENERAL (which is global table in class)
and looks like:
I want to create a string line which goes like:
FLGDEFAULT_ADR12#URI_ADDR#URI_TYPE#TELNR_LONG#COUNTRY_ADR2#R3_USER#DFT_RECEIV
I tried utilising DDIF_FIELDINFO_GET but entered into a runtime error because I think this internal table doesn't relate to any repository object?
Need some advice to achieve this or I'll have to rewrite lots of logic.
Regards,
Shailesh
lv_string = REDUCE #(
INIT lv_tabinput = ``
FOR <ls_component> IN
CAST cl_abap_structdescr(
CAST cl_abap_tabledescr(
cl_abap_tabledescr=>describe_by_data( <lt_tabinput> ) )->get_table_line_type( )
)->get_components( )
INDEX INTO lv_index
NEXT lv_tabinput &&= COND #( WHEN lv_index GT 1 THEN `#` ) && <ls_component>-name ).
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
76 | |
9 | |
8 | |
6 | |
6 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.