‎2010 May 05 11:31 AM
Hi all, i'm trying to Read from an internal dynamique table <it_tab> into <ls_tab> i need to add a WHERE at the end
I tried
READ TABLE <it_tab> INTO <ls_tab> WITH KEY (clause_where).
And
LOOP AT <it_tab>ASSIGNING <ls_tab> WHERE (clause_where).
But it's not working :s :s s
PS: clause _where is a String TYPE
Regards.
Mehdi
‎2010 May 05 11:56 AM
you must wait for
http://www.sdn.sap.com/irj/sdn/nw-70ehp2?rid=/webcontent/uuid/1009fbb7-fd08-2d10-0182-852b6fa05f08">sap [original link is broken] [original link is broken]
altenatives:
1) read table
DATA key1(72) .
DATA key2(72) .
key1 =...
read table itab into wa with key (key1) = x.
(key2) = z.
2) GENERATE SUBROUTINE POOL prog NAME genprog MESSAGE message
LINE line WORD word.
A.
‎2010 May 05 11:56 AM
you must wait for
http://www.sdn.sap.com/irj/sdn/nw-70ehp2?rid=/webcontent/uuid/1009fbb7-fd08-2d10-0182-852b6fa05f08">sap [original link is broken] [original link is broken]
altenatives:
1) read table
DATA key1(72) .
DATA key2(72) .
key1 =...
read table itab into wa with key (key1) = x.
(key2) = z.
2) GENERATE SUBROUTINE POOL prog NAME genprog MESSAGE message
LINE line WORD word.
A.
‎2010 May 06 4:56 PM
I found the solution somewhere and it wokrs that's what i found :
LOOP AT <table> ASSIGNING <ligne_table> .
MOVE-CORRESPONDING <ligne_table2> TO <ligne_output>.
ASSIGN COMPONENT ds_tabx-forkey OF STRUCTURE <ligne_table> TO <ls>.
READ TABLE <table1> INTO <ligne_table1> WITH KEY (clause_where3) = <ls>.
IF sy-subrc = 0.
MOVE-CORRESPONDING <ligne_table1> TO <ligne_output>.
ENDIF.
APPEND <lligne_output> TO <table_output>.
ENDLOOP.
Regards iMedix.