Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Dynamic Read

Former Member
0 Likes
224

Hi,

I have a dynamic internal table <dyn_tab>.I want to read this table with a key field.

Ex: READ TABLE <dyn_tab> ASSIGNING <dyn_wa> WITH KEY "THE KEY FLD" = <lfs_fld>.

Please suggest how to achieve above( "THE KEY FLD" ).

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
198

Hi,

Use tokens. If you know the name of the key field follow this code:


" Lets say the key field is VBELN.
constants c_vbeln(5) type c value 'VBELN'.

READ TABLE <dyn_tab> ASSIGNING <dyn_wa> WITH KEY (c_vbeln)  =  <lfs_fld>.

Br,

Advait

1 REPLY 1
Read only

Former Member
0 Likes
199

Hi,

Use tokens. If you know the name of the key field follow this code:


" Lets say the key field is VBELN.
constants c_vbeln(5) type c value 'VBELN'.

READ TABLE <dyn_tab> ASSIGNING <dyn_wa> WITH KEY (c_vbeln)  =  <lfs_fld>.

Br,

Advait