Skip to Content
author's profile photo Former Member
Former Member

Select Query

Hi,

I have written a code as above but it is giving timeout error, what I can do to resolve this problem.

SELECT bukrs belnr gjahr j_1ibuzei witht wt_withcd

FROM with_item INTO corresponding fields of TABLE

data_tab FOR ALL ENTRIES IN

bkpftab WHERE bukrs = bkpftab-bukrs AND

belnr = bkpftab-belnr AND

gjahr = bkpftab-gjahr AND

wt_qbshh NE 0 AND

koart = 'K' AND

wt_acco IN zvendor AND

qsrec IN zrec AND

wt_stat = ' ' AND

j_1ibuzei <> '000'.

Thanks.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jul 02, 2007 at 02:35 PM

    try to avoid corresponding fields of table

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jul 02, 2007 at 02:40 PM

    are u checking if the table used in FOR ALL ENTRIES is initial before the select statement

    <b>IF NOT bkpftab[] is initial.</b>

    SELECT bukrs belnr gjahr j_1ibuzei witht wt_withcd

    FROM with_item INTO corresponding fields of TABLE

    data_tab FOR ALL ENTRIES IN

    bkpftab WHERE bukrs = bkpftab-bukrs AND

    belnr = bkpftab-belnr AND

    gjahr = bkpftab-gjahr AND

    wt_qbshh NE 0 AND

    koart = 'K' AND

    wt_acco IN zvendor AND

    qsrec IN zrec AND

    wt_stat<b> is initial</b> AND

    j_1ibuzei <> '000'.

    <b>

    ENDIF.</b>

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.