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

CDHDR table query taking long time

Former Member
0 Likes
1,480

Hi all,

Select query from CDHDR table is taking long time,in where condition i am giving OBJECTCLASS = 'MAT_FULL' udate = sy-datum and langu = 'EN'.

any suggestion to improve the performance.i want to select all the article which got changed on current date

regards

shibu

1 ACCEPTED SOLUTION
Read only

ThomasZloch
Active Contributor
0 Likes
1,209

This will always be slow for large data volumes, since CDHDR is designed for quick access by object ID (in this case material number), not by date.

I'm afraid you would need to introduce a secondary index on OBJECTCLAS and UDATE, if that query is crucial enough to warrant the additional disk space and processing time taken by the new index.

Greetings

Thomas

5 REPLIES 5
Read only

former_member195383
Active Contributor
0 Likes
1,209

Hi..

please make sure that u are not using select * , and are selcting only those fields which are required...That may be one reason of the select query taking longtime..U can paste the select query so that we can get a clearer picture...

Regards

Rudra

Read only

ThomasZloch
Active Contributor
0 Likes
1,210

This will always be slow for large data volumes, since CDHDR is designed for quick access by object ID (in this case material number), not by date.

I'm afraid you would need to introduce a secondary index on OBJECTCLAS and UDATE, if that query is crucial enough to warrant the additional disk space and processing time taken by the new index.

Greetings

Thomas

Read only

Former Member
0 Likes
1,209

Hello

1. Use your query in LOOP...ENDLOOP with OBJECTID field.

2. Make a secondary index.

Read only

alison_lloyd
Active Participant
0 Likes
1,209

Have you got a range of objectids you could use?

eg. 0100000000 - 090000000 depending on your matnr range

Read only

Former Member
0 Likes
1,209

solved.Thanks for all the reply