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

PM_ORDER_DATA_READ running too long

I'm using the FM - PM_ORDER_DATA_READ to extract workorder data for divestiture. But the program execution time is running over few days due to the

LOOP AT icaufv-aufnr.

Another thing I have noticed - Unless the FM is run as a backgroud job for large data, SAP errors 'out of memory'.

Can anyone suggest how to extract all workorder info and quicken the execution time?

Thanks

G

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

4 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Oct 13, 2006 at 05:31 PM

    Instead of using the FM, select the data directly from <b>AUFK - Order master data</b> table.

    This problem is due the long execution time.

    Basis people will set the execution time for the program, say 10 minutes or 20 minutes. If it exceeds it will through the error.

    If the table AUFK doesn't contain all the data, chek the FM in debugging mode and see what are all the tables/ select queries SAP is using and get the data from those tables.

    If u directly selecting the data table u can directly use <b>for all entries</b> in the select query.

    Regards,

    Prakash.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 13, 2006 at 06:10 PM

    The required fields are all not in AUFK.

    Here is the list of fields -

    caufv-aufnr

    caufv-werks

    caufv-plnty

    caufv-plnnr

    caufv-plnal

    caufv-aufpl

    caufv-rsnum

    caufv-gltrp

    caufv-gstrp

    caufv-gltrs

    caufv-gstrs

    caufv-gltri

    caufv-gstri

    caufv-auart

    caufv-ktext

    [???]-priok

    [???]-equnr

    [???]-bautl

    [???]-iloan

    [???]-iwerk

    [???]-ingpr

    [???]-gewrk

    [???]-ilart

    [???]-vawrk

    [???]-vaplz

    From which tables can I select the [???]-fields, satisfying the werks = <..>and aufnr = <..> conditions?

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      I am not sure of this table Ganadeep. But what u can do is execute the FM in debugging mode by giving the aufnr keep break point like this Breakpoint -> Breakpoints at -> Type <b>Select</b> and press enter. Now press F8 it will stop at all the select queries, so check what are the tables they are using to get the data.

      Hope it is useful.

      Regards,

      Prakash.

  • author's profile photo Former Member
    Former Member
    Posted on Oct 13, 2006 at 06:19 PM

    Have you checked OSS notes? Look at 399420.

    Rob

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 13, 2006 at 06:34 PM

    Thanks a lot guys.

    I'm looking into the OSS notes.

    The db tables for [???]-fields are AFIH and HIKO. This solves the problem for now as now I can extract same results without the FM.

    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.