Skip to Content
0

Load data from application server into internal dynamic table using the fields of a table.

May 25, 2017 at 01:33 PM

147

avatar image

Hi,

I have a user maintained internal table, in which I have the OpenHub name, field and type(say T1).

Now I want to fetch data from application server based on the data in the internal table T1 and store it in a dynamic internal table T2.

So from the internal table T,1 I'll get all the fields for a particular user entered openhub.

I am not able to understand how to write code for fetching data from application server based on the data present in internal Table T1.

Can anyone please help me with this.

Thanks in advance.

10 |10000 characters needed characters left characters exceeded

I have no idea what openhub is, please can you clarify your question. Are you trying to dynamically specify which fields should be selected from a table, or trying to use dynamic conditions, or ...?

0

Hi Mike,

Yes I am trying to dynamically specify the field from a table.

So for this I believe I have to create a dynamic structure.

0
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
Mike Pokraka May 26, 2017 at 08:45 AM
0

OK, for dynamic selection fields I can suggest two options:

1. Specify a table of field names as your select field list - a simple table of strings should work

select (field_table) from blah into table @data(my_result_table).

2. Create your result table dynamically beforehand and then do:

select * from blah into corresponding fields of table my_dynamic_table. 
Show 3 Share
10 |10000 characters needed characters left characters exceeded

Hi Mike,

I read the question as fetching data from an external database rather than an SAP table, so is this actually the correct answer ? If so, then perhaps the OP should learn to phrase his questions properly.

Rich

0

Hi Richard,

Yes I found it confusing too, which is why I asked him to clarify. Perhaps you missed the question comments? Such a great feature of the new much easier and friendlier to use SCN, impossible to miss... (sarcasm alert).

0

<DUCKS as the sarcasm flies over my left shoulder>

1
Richard Harper May 26, 2017 at 07:10 AM
0

Are you talking about Black Duck Open Hub (used to be Ohio ?)

Rich

Share
10 |10000 characters needed characters left characters exceeded