Application Development 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: 

DFKKOP Select is slow

Former Member
0 Kudos

Hi. I am having troubles trying to SELECT data from the table DFKKOP. The thing is I only have the field XBLNR for the WHERE filter and it is not a key field. My SELECT is as follows:

if t_data_folder[] is not initial.

SELECT opbel opupw opupk xblnr bukrs

       FROM dfkkop

       INTO TABLE t_dfkkop

       FOR ALL ENTRIES IN t_data_folder

       WHERE   xblnr = t_data_folder-xblnr.

ENDIF.

The data table t_data_folder is filled with data from a .CSV file from excel. It has around 150 entries and this SELECT is needing about 10 minutes to execute.

Can anybody show me a way to improve the performance?

Thanks,

1 ACCEPTED SOLUTION

kathryn_mcgallicher
Active Participant
0 Kudos

Hello,

Try adding DFKKKO to the select.  Use xblnr in DFKKKO to get opbel and then use opbel to get the items in DFKKOP.

K--

4 REPLIES 4

kathryn_mcgallicher
Active Participant
0 Kudos

Hello,

Try adding DFKKKO to the select.  Use xblnr in DFKKKO to get opbel and then use opbel to get the items in DFKKOP.

K--

0 Kudos

Thanks! That was really helpful

0 Kudos

Put an Index on field XBLNR of table DFKKOP

Transaction SE11 -> Database Table

menu: GoTo->Indexes -> Create-Button (white sheet)  // Indexname should start with "Z"

Chose: Non-unique index and index on all database systems and add the field by using the button "Table Fields"

Create the index into the development system and transport to productiv system.

But take care do not Transport the index to productive while other users are working. It could create a dump.

0 Kudos

thank you for the answer, but I fixed it by adding dfkkko to the select and acceding then by opbel to dfkkop. This way I don't have to make any changes in the table