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

Into corresponding fields

Former Member
0 Likes
2,797

Hi

I have one performance issue problem, in program i declare structure, internal table and work area. Here in select query i specify into corresponding fields table <it>. here i used into corresponding fields of table is it reduce the performance?

Please tell me.

Thanks.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,966

Hi,

We generally dont go for Corresponding field due to performance issue its better you go with the same sturctue.

you can have a look in the link below:

http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb39eb358411d1829f0000e829fbfe/content.htm

With luck,

Pritam.

Edited by: Pritam Ghosh on Jul 11, 2008 3:24 PM

10 REPLIES 10
Read only

Former Member
0 Likes
1,967

Hi,

We generally dont go for Corresponding field due to performance issue its better you go with the same sturctue.

you can have a look in the link below:

http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb39eb358411d1829f0000e829fbfe/content.htm

With luck,

Pritam.

Edited by: Pritam Ghosh on Jul 11, 2008 3:24 PM

Read only

0 Likes
1,966

Hi Pritam,

Thanks to your answer.

In my requirement i am writing start routine in BW. Here the structure is having around 80 fields, But i want only 10 fields to retrieve data. If i am not used into corresponding fields program is going to dump.

Is there any other possibility, for performance.

Please tell me.

Read only

0 Likes
1,966

Hi,

It is bett that first you create an internal table with the Required fields.

And the work area will be the internal table type.

Now in the Select Statement Select only those fields that you need.

In this case no need to use 'Corresponding fields of table' statement.

I hope i am Clear.

revert back if any confusion.

Regards,

Sujit

Read only

0 Likes
1,966

Never use into corresponding fields. First its a performance issue and Second QA team would not pass the code. Always use the field names like SELECT field1 field2 ....into table it_ from table. Make sure that filed1 field2 ... are in the same order as they are in the transparent table.

Regards

Samson.

Read only

1,966

>

> Never use into corresponding fields. First its a performance issue and Second QA team would not pass the code. Always use the field names like SELECT field1 field2 ....into table it_ from table.

Incorrect statement, as I have proven otherwise, see [here|;. Do your own research and come back with the results.

Read only

Former Member
0 Likes
1,966

Hi,

Get the records in to the internal table....

Dont declare structure for internal table rather you define internal table of same structure as that table and declare workarea and display the fields required...

If there are many entries in the table or if the table is TRANSACTION DATA table kind then go for INTO CORRESPONDING FIELDS as transaction DATA tables will have more records and they will keep updating the records..

Hope this would help you

Regards

Narin Nandivada

Read only

ThomasZloch
Active Contributor
0 Likes
1,966

I just did some research on this matter.

In your 80/10 example it is essential that you declare a target table with only those 10 columns.

Then it does not matter performancewise if you are selecting by "* INTO CORRESPONDING FIELDS OF ... " or "F1 F2 F3 ... INTO ...".

Thomas

Read only

Former Member
0 Likes
1,966

If you have a performance issue, it's not due to MOVE-CORRESPONDING.

Rob

Read only

0 Likes
1,966

never use into corresponding fields when we are looking for perfromance issue. as you said 10 fields you are going to display. then

decalre the internal table body and work area by using those fields (which are required to display output).

select <require fields> into table <internal table body> from <dbtable> where <condition>.

if you declare your internal table like below which makes your performance better.

TYPES: begin of tw_itab,

-


,

-


,

-


,

end of tw_itab,

tt_itab type standard table of tw_itab.

DATA : lw_itab type tw_itab,

lt_itab type tt_itab.

regards.

sriram.

Read only

Former Member
0 Likes
1,966

Hi sri,

Actually we go for INTO CORRESPONDING FIELDS only if the structure of the source and target is not same. As the system has to perform aen extra effort in assigning the correct values to the correct fields based on the field names,it reduces the performance.However,it depends on the requirement ...It it is unavoidablethen go for INTO CORRESPONDING FIELDS or else make sure that your target and source structure are similar with respect to their order..

Regards,

Bhumika