Query execution takes long time

Hi All,
I have one critical problem in my production system.
I have three sales related queries in the production system and when i try to execute it in the BEx analyser(in Microsoft excle) it will take too much time and at last it will give am error that "Time Limit Exceeded" .
Actually we have created these three queries on one Infoset and that Infoset contains three DSOs and two master data.
Please give me the proper solution and help me to solve this production problem.

Dear James,
first give some filter conditions on the query and try to restrict for lesser volume of data.from the message it is evident that may be you are trying to fetch large volume of data.so please execute the query once in RSRT and try to find the solution in that.there you can get all the statistics reagrding the query.if still you cant find please let me know the message you are getting in RSRT.then we can give a viable solution for that.
hope you might aware of all the options reagarding RSRT.
assign points if it helps..
Thanks & Regards,
Ashok.

Similar Messages

  • Analyze a Query which takes longer time in Production server with ST03 only

    Hi,
    I want to Analyze a Query which takes longer time in Production server with ST03 t-code only.
    Please provide me with detail steps as to perform the same with ST03
    ST03 - Expert mode- then I need to know the steps after this. I have checked many threads. So please don't send me the links.
    Write steps in detail please.
    <REMOVED BY MODERATOR>
    Regards,
    Sameer
    Edited by: Alvaro Tejada Galindo on Jun 12, 2008 12:14 PM

    Then please close the thread.
    Greetings,
    Blag.

  • Query Prediction takes long time - After upgrade DB 9i to 10g

    Hi all, Thanks for all your help.
    we've got an issue in Discoverer, we are using Discoverer10g (10.1.2.2) with APPS and recently we upgraded Oracle DatBase from 9i to 10g.
    After Database upgrade, when we try to run reports in Discoverer plus taking long time for query prediction than used to be(double/triple), only for query prediction taking long time andthen takes for running query.
    Have anyone got this kind of issues seen before, could you share your ideas/thoughts that way i can ask DBA or sysadmin to change any settings at Discoverer server side
    Thanks in advance
    skat

    Hi skat
    Did you also upgrade your Discoverer from 9i to 10g or did you always have 10g?
    If you weren't always on 10g, take a look inside the EUL5_QPP_STATS table by running SELECT COUNT(*) FROM EUL5_QPP_STATS on both the old and new systems
    I suspect you may well find that there are far more records in the old system than the new one. What this table stores is the statistics for the queries that have been run before. Using those statistics is how Discoverer can estimate how long queries will take to run. If you have few statistics then for some time Discoverer will not know how long previous queries will take. Also, the statistics table used by 9i is incompatible with the one used by 10g so you can't just copy them over, just in case you were thinking about it.
    Personally, unless you absolutely rely on it, I would turn the query predictor off. You do this by editing your PREF.TXT (located on the middle tier server at $ORACLE_HOME\Discoverer|util) and change the value of QPPEnable to 0. AFter you have done this you need to run the Applypreferences script located in the same folder and then stop and start your Discoverer service. From that point on queries will no longer try to predict how long they will take and they will just start running.
    There is something else to check. Please run a query and look at the SQL. Do you by change see a database hint called NOREWRITE? If you do then this will also cause poor performance. Should you see this let me know and I will let you know how to override it.
    If you have always been on 10g and you have only upgraded your database it could be that you have not generated your database statistics for the tables that Discoverer is using. You will need to speak with your DBA to see about having the statistics generated. Without statistics, the query predictor will be very, very slow.
    Best wishes
    Michael

  • Miro execution takes long time

    Hi Experts,
    While posting Credit memo for Purchase returns in MIRO, processing takes long time, it takes hours to complete entire posting.
    For each inputs say while entering PO number, selecting tax code, selecting 'calculate tax' checkbox it takes minimum 10-15 mins for each to process.
    I processed with following parameters.
    PO contains 10 line items.
    Tax code : C2(ED(1021)+VAT 5%)
    Indicator: Goods Items/Delivery Costs/Both.
    Version: EHP4 FOR SAP ERP 6.0 / NW7.01
    Please advice to resolve this issue.
    Regards,
    Sathish

    Hello Sathish,
    this looks very strange. I guess you have some bad performing user exit inside. Otherwise MIRO should not perform that bad for the document with 10 items.
    If you don't want to create an SAP message for that, you can try tracing an execution with ST12 transaction (more details here: http://wiki.sdn.sap.com/wiki/display/ABAP/SingleTransactionAnalysis
    Regards,
      Yuri

  • Report execution takes long time

    Dear all,
    we have a report which takes long time to exceute due to select statement.. here is the code..
    SELECT vkorg vtweg spart kunnr kunn2 AS division FROM knvp
        INTO CORRESPONDING FIELDS OF TABLE hier
        WHERE kunn2 IN s_kunnr
        AND   vkorg EQ '0001'
        AND   parvw EQ 'ZV'.
        l_parvw = 'WE'.
    SORT hier.
    * select all invoices within the specified invoice creation dates.
      CHECK NOT hier[] IS INITIAL.
      SELECT vbrk~vbeln vbrk~fkart vbrk~waerk vbrk~vkorg vbrk~vtweg vbrk~spart vbrk~knumv
             vbrk~konda vbrk~bzirk vbrk~pltyp vbrk~kunag vbrp~vbeln vbrp~aubel vbrp~posnr
             vbrp~fkimg vbrp~matnr vbrp~prctr vbpa~kunnr
             vbrp~pstyv vbrp~uepos
             vbrp~kvgr4  vbrp~ean11          
        INTO CORRESPONDING FIELDS OF TABLE it_bill
        FROM vbrk INNER JOIN vbrp ON vbrp~vbeln = vbrk~vbeln
                  INNER JOIN vbpa ON vbpa~vbeln = vbrk~vbeln
        FOR ALL entries IN hier
        WHERE (lt_syntax)
        AND   vbrk~vbeln IN s_vbeln
    *    AND   vbrk~erdat IN r_period
        AND   vbrk~fkdat IN r_period       
        AND   vbrk~rfbsk EQ 'C'
        AND   vbrk~vkorg EQ hier-vkorg
        AND   vbrk~vtweg EQ hier-vtweg
        AND   vbrk~spart EQ hier-spart.
    Can anyone say about how to reduce the execution time.?
    Edited by: Thomas Zloch on Sep 22, 2010 2:46 PM - please use code tags

    Hi
    first of all never use move corressponding.
    Rather you should declare a work area for table hier.
    select values into the work area and then append that workarea into the table hier.
    In case of for all entries include all the primary keys in the selection and for the keys which are of no use declare constants with initial valules like:
    'prmkey' is a primary field for table 'tab1' .
    Constants: field1 type tab1-prmkey value initial.
    and then in your where condition write.
    prmkey GE field1.
    I hope it is clear to you now.
    Thanks
    lalit Gupta

  • Query Saving takes long time and giving error

    Hi Gurus,
    I am creating one query that have lot of calculations (CKF & RKF).
    When I am trying to save this query it is taking long time and it is giving error like RFC_ERROR_SYSTEM_FAILURE, Query Designer must be restarted, further work not possible.
    Please give me the solution for this.
    Thanks,
    RChowdary

    Hi Chowdary,
    Check the following note: 316470.
    https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=316470
    The note details are:
    Symptom
    There are no authorizations to change roles. Consequently, the system displays no roles when you save workbooks in the BEx Analyzer. In the BEx browser, you cannot move or change workbooks, documents, folders and so on.
    Other terms
    BW 2.0B, 2.0A, 20A, 20B, frontend, error 172, Business Explorer,
    RFC_ERROR_SYSTEM_FAILURE, NOT_AUTHORIZED, S_USER_TCD, RAISE_EXCEPTION,
    LPRGN_STRUCTUREU04, SAPLPRGN_STRUCTURE, PRGN_STRU_SAVE_NODES
    Reason and Prerequisites
    The authorizations below are not assigned to the user.
    Solution
    Assign authorization for roles
    To assign authorizations for a role, execute the following steps:
    1. Start Transaction Role maintenance (PFCG)
    2. Select a role
    3. Choose the "Change" switch
    4. Choose tab title "Authorizations"
    5. Choose the "Change authorization data" switch
    6. Choose "+ Manually" switch
    7. Enter "S_USER_AGR" as "Authorization object"
    8. Expand "Basis: Administration"/"Authorization: Role check""
    9. From "Activity" select "Create or generate" and others like "Display" or "Change"
    10. Under "Role Name", enter all roles that are supposed to be shown or changed. Enter "*" for all roles.
    11. You can re-enter authorization object "S_USER_AGR" for other activities.
    Assign authorization for transactions
    If a user is granted the authorization for changing a role, he/she should also be granted the authorization for all transactions contained in the role. Add these transaction codes to authorization object S_USER_TCD.
    1. Start the role maintenance transaction (PFCG).
    2. Select a role.
    3. Click on "Change".
    4. Choose the "Authorizations" tab.
    5. Click on "Change authorization data".
    6. Click on "+ manually".
    7. Specify "S_USER_TCD" as "Authorization object".
    8. Expand "Basis - Administration"/"Authorizations: Transactions in Roles".
    9. Under "Transaction", choose at least "RRMX" (for BW reports), "SAP_BW_TEMPLATE" (for BW Web Templates), "SAP_BW_QUERY" (for BW Queries and/or "SAP_BW_CRYSTAL" (for Crystal reports) or "*". Values with "SAP_BW_..." are not transactions, they are special node types (see transaction code NODE_TYPE_DEFINITION).
    Using the SAP System Trace (Transaction ST01), you can identify the transaction that causes NOT_AUTHORIZED.
    Prevent user assignment
    Having the authorization for changing roles, the user is not only able to change the menu but also to assign users. If you want to prevent the latter, the user must loose the authorization for Transactions User Maintenance (SU01) and Role maintenance (PFCG).
    Z1>Note
    Refer to Note 197601, which provides information on the different display of BEx Browser, BEx Analyzer and Easy Access menu.
    Please refer to Note 373979 about authorizations to save workbooks.
    Check in the transaction ST22 for more details on the Query designer failure or query log file.
    With Regards,
    Ravi Kanth.
    Edited by: Ravi kanth on Apr 9, 2009 6:02 PM

  • Query Execution taking Longer Time

    Hi BI Gurus,
    There is one some ABC query which was built on multiprovider, when I am trying to execute it in BEx analyzer in production system it is taking long run and then giving short dump. I have checked data in the multiprovider it is not more than 1lac records. Can any one tell me what is the problem and how can I find the roote cause?
    Thanks in advance,
    Venkat

    Hi,
    Even I am facing the same problem above. I am trying to fetch results from a cursor which has subquery running over the db link and placing the results set in a csv file using client_io package. When I run the cursor directly from database (11G), it takes not more than 3-4 min to get the results back. But when I run the same cursor via oracle forms 10G, the query in local database keep on waiting for hours to get results from remote database with "SQL*Net message from dblink". Session on local database remains in active status with state as "Waiting" while the session on remote database goes inactive with state as waiting for event "SQL*Net message from client"
    This is confusing me since the same query when ran directly from backend fetches results soon.
    Please let me know if anyone can help here
    Thanks
    Garima

  • Query execution taking longer time in Oracle form 10g !!

    Hi,
    I'm generating a report through Oracle form ( forms 10g) and its taking 3-4 hours to finish. But when I run the same report query in (Oracle 11g) database, it gets executed in less than 40 mins.
    The form takes only from and to date as input.
    I tried hardcoring the date in the Oracle Form and then the report takes only 40 mins to generate.
    I tried various approaches like changing the datatypes of form variable and correspondingly changing the query, but met with no success.
    When the report in run through the form , we can see the query getting run in backend for nearly 3 hrs !!! tats really confusing !!
    Please let me know, if anybody got any idea on this problem??

    Hi,
    Even I am facing the same problem above. I am trying to fetch results from a cursor which has subquery running over the db link and placing the results set in a csv file using client_io package. When I run the cursor directly from database (11G), it takes not more than 3-4 min to get the results back. But when I run the same cursor via oracle forms 10G, the query in local database keep on waiting for hours to get results from remote database with "SQL*Net message from dblink". Session on local database remains in active status with state as "Waiting" while the session on remote database goes inactive with state as waiting for event "SQL*Net message from client"
    This is confusing me since the same query when ran directly from backend fetches results soon.
    Please let me know if anyone can help here
    Thanks
    Garima

  • Why update query takes  long time ?

    Hello everyone;
    My update query takes long time.  In  emp  ( self testing) just  having 2 records.
    when i issue update query , it takes long time;
    SQL> select  *  from  emp;
      EID  ENAME     EQUAL     ESALARY     ECITY    EPERK       ECONTACT_NO
          2   rose              mca                  22000   calacutta                   9999999999
          1   sona             msc                  17280    pune                          9999999999
    Elapsed: 00:00:00.05
    SQL> update emp set esalary=12000 where eid='1';
    update emp set esalary=12000 where eid='1'
    * ERROR at line 1:
    ORA-01013: user requested cancel of current operation
    Elapsed: 00:01:11.72
    SQL> update emp set esalary=15000;
    update emp set esalary=15000
      * ERROR at line 1:
    ORA-01013: user requested cancel of current operation
    Elapsed: 00:02:22.27

    Hi  BCV;
    Thanks for your reply but it doesn't provide output,  please  see   this.
    SQL> update emp set esalary=15000;
    ........... Lock already occured.
    >> trying to trace  >>
    SQL> select HOLDING_SESSION from dba_blockers;
    HOLDING_SESSION
                144
    SQL> select sid , username, event from v$session where username='HR';
    SID USERNAME     EVENT
       144   HR    SQL*Net message from client
       151   HR    enq: TX - row lock contention
       159   HR    SQL*Net message from client
    >> It  does n 't  provide  clear output about  transaction lock >>
    SQL> SELECT username, v$lock.SID, TRUNC (id1 / POWER (2, 16)) rbs,
      2  BITAND (id1, TO_NUMBER ('ffff', 'xxxx')) + 0 slot, id2 seq, lmode,
      3  request
      4  FROM v$lock, v$session
      5  WHERE v$lock.TYPE = 'TX'
      6  AND v$lock.SID = v$session.SID
      7  AND v$session.username = USER;
      no rows selected
    SQL> select MACHINE from v$session where sid = :sid;
    SP2-0552: Bind variable "SID" not declared.

  • Query take long time

    I m running a query taking more time more than 20 minutes. But if I am changing the values in the
    where clause, its doing fast. I am not changing the query , only i change the numeric value used in the
    where condtion. I thing its a factor of LOCK. How to resolve it. how to make the query return resut even
    row is being locked. thanks

    QUERY 1:
    PROD> select count(*) from patient_ad a,patient_master_data p , patient_contracts c
    2 where a.patient_id=p.patient_id and c.patient_id = a.patient_id and
    3 to_date(a.admit_date,'dd/mm/yyyy') >= '29/12/2008' and
    4 to_date(a.admit_date,'dd/mm/yyyy') <= '17/12/2009' and
    5 p.nationality_code <> 16 and c.CONTRACT_NO= 2207;
    Execution Plan
    Plan hash value: 801996662
    | Id | Operation | Name |
    | 0 | SELECT STATEMENT | |
    | 1 | SORT AGGREGATE | |
    | 2 | NESTED LOOPS | |
    | 3 | NESTED LOOPS | |
    |* 4 | INDEX RANGE SCAN | PATIENT_CONTRACTS_NDX2 |
    |* 5 | TABLE ACCESS BY INDEX ROWID| PATIENT_AD |
    |* 6 | INDEX RANGE SCAN | PATIENT_AD_NDX1 |
    |* 7 | TABLE ACCESS BY INDEX ROWID | PATIENT_MASTER_DATA |
    |* 8 | INDEX UNIQUE SCAN | PK_PATIENT_MASTER_DATA |
    Predicate Information (identified by operation id):
    4 - access("C"."CONTRACT_NO"=2207)
    5 - filter(TO_DATE(INTERNAL_FUNCTION("A"."ADMIT_DATE"),'dd/mm/yyyy')<
    ='17/12/2009' AND TO_DATE(INTERNAL_FUNCTION("A"."ADMIT_DATE"),'dd/mm/yyy
    y')>='29/12/2008')
    6 - access("C"."PATIENT_ID"="A"."PATIENT_ID")
    7 - filter("P"."NATIONALITY_CODE"<>16)
    8 - access("A"."PATIENT_ID"="P"."PATIENT_ID")
    Note
    - rule based optimizer used (consider using cbo)
    THIS QUERY TAKING A LONG TIME EVEN AFTER 24 HOURS NOT YIELDING ANY RESULT.
    QUERY2:
    PROD> select count(*) from patient_ad a,patient_master_data p , patient_contracts c
    2 where a.patient_id=p.patient_id and c.patient_id = a.patient_id and
    3 to_date(a.admit_date,'dd/mm/yyyy') >= '29/12/2008' and
    4 to_date(a.admit_date,'dd/mm/yyyy') <= '17/12/2009' and
    5 p.nationality_code <> 16 and c.CONTRACT_NO= 2207;
    Execution Plan
    Plan hash value: 801996662
    | Id | Operation | Name |
    | 0 | SELECT STATEMENT | |
    | 1 | SORT AGGREGATE | |
    | 2 | NESTED LOOPS | |
    | 3 | NESTED LOOPS | |
    |* 4 | INDEX RANGE SCAN | PATIENT_CONTRACTS_NDX2 |
    |* 5 | TABLE ACCESS BY INDEX ROWID| PATIENT_AD |
    |* 6 | INDEX RANGE SCAN | PATIENT_AD_NDX1 |
    |* 7 | TABLE ACCESS BY INDEX ROWID | PATIENT_MASTER_DATA |
    |* 8 | INDEX UNIQUE SCAN | PK_PATIENT_MASTER_DATA |
    Predicate Information (identified by operation id):
    4 - access("C"."CONTRACT_NO"=2207)
    5 - filter(TO_DATE(INTERNAL_FUNCTION("A"."ADMIT_DATE"),'dd/mm/yyyy')<
    ='17/12/2009' AND TO_DATE(INTERNAL_FUNCTION("A"."ADMIT_DATE"),'dd/mm/yyy
    y')>='29/12/2008')
    6 - access("C"."PATIENT_ID"="A"."PATIENT_ID")
    7 - filter("P"."NATIONALITY_CODE"<>16)
    8 - access("A"."PATIENT_ID"="P"."PATIENT_ID")
    Note
    - rule based optimizer used (consider using cbo)
    THIS QUERY RETURNS THE RESULT WITHIN 1 MINUTES.

  • CV04N takes long time to process select query on DRAT table

    Hello Team,
    While using CV04N to display DIR's, it takes long time to process select query on DRAT table. This query includes all the key fields. Any idea as to how to analyse this?
    Thanks and best regards,
    Bobby
    Moderator message: please read the sticky threads of this forum, there is a lot of information on what you can do.
    Edited by: Thomas Zloch on Feb 24, 2012

    Be aware that XP takes approx 1gb of your RAM leaving you with 1gb for whatever else is running. MS Outlook is also a memory hog.
    To check Virtual Memory Settings:
    Control Panel -> System
    System Properties -> Advanced Tab -> Performance Settings
    Performance Options -> Adavanced Tab - Virtual Memory section
    Virtual Memory -
    what are
    * Initial Size
    * Maximum Size
    In a presentation at one of the Hyperion conferences years ago, Mark Ostroff suggested that the initial be set to the same as Max. (Max is typically 2x physical RAM)
    These changes may provide some improvement.

  • My query take long time..

    The output of tkprof of my trace file is :
    SELECT ENEXT.NUM_PRSN_EMPLY ,ENEXT.COD_BUSUN ,ENEXT.DAT_CALDE ,ENEXT.COD_SHFT
    FROM
    AAC_EMPLOYEE_ENTRY_EXITS5_VIW ENEXT ,PDS.PDS_EMPLOYEES EMPL ,
    PDS.PDS_EMPLOYMENT_TYPES EMPTYP ,PDS.PDS_PAY_CONDITIONS PAYCON WHERE
    ENEXT.DAT_CALDE BETWEEN :B6 AND :B5 AND ENEXT.NUM_PRSN_EMPLY IN (SELECT
    ATT21 FROM APPS.GLOBAL_TEMPS WHERE ATT1 = 'PRSN') AND ENEXT.NUM_PRSN_EMPLY =
    EMPL.NUM_PRSN_EMPLY AND EMPL.EMTYP_COD_EMTYP = EMPTYP.COD_EMTYP AND
    EMPTYP.LKP_COD_STA_PAY_EMTYP <> 3 AND
    NVL(EMPL.LKP_MNTLY_WITHOUT_ENEXT_EMPLY,2) <> 1 AND EMPL.PCOND_COD_STA_PCOND
    = PAYCON.COD_STA_PCOND AND NVL(EMPL.LKP_MNTLY_WITHOUT_ENEXT_EMPLY,2) <> 1
    AND PAYCON.LKP_FLG_STA_PAY_PCOND = 1 AND ENEXT.DAT_CALDE >=
    EMPL.DAT_EMPLT_EMPLY AND ENEXT.DAT_CALDE <= NVL(EMPL.DAT_DSMSL_EMPLY,
    TO_DATE('15001229','YYYYMMDD')) AND 1 = (CASE WHEN
    ENEXT.LKP_STA_HOLIDAY_CALNR = 2 AND ENEXT.LKP_CAT_SHFT_SHTAB = 1 AND
    ENEXT.TYP_DAY BETWEEN 4 AND 6 THEN 0 WHEN ENEXT.LKP_STA_HOLIDAY_CALNR = 2
    AND ENEXT.LKP_CAT_SHFT_SHTAB = 1 AND ENEXT.TYP_DAY NOT BETWEEN 4 AND 6 THEN
    1 WHEN ENEXT.LKP_STA_HOLIDAY_CALNR = 2 AND ENEXT.LKP_CAT_SHFT_SHTAB = 2
    THEN 0 WHEN ENEXT.LKP_STA_HOLIDAY_CALNR = 1 AND ENEXT.LKP_CAT_SHFT_SHTAB =
    1 THEN 1 WHEN ENEXT.LKP_STA_HOLIDAY_CALNR = 1 AND ENEXT.LKP_CAT_SHFT_SHTAB =
    2 THEN 0 END) AND ENEXT.LKP_COD_DPUT_BUSUN = NVL(:B4 ,
    ENEXT.LKP_COD_DPUT_BUSUN) AND ENEXT.LKP_COD_MANAG_BUSUN = NVL(:B3 ,
    ENEXT.LKP_COD_MANAG_BUSUN) AND ENEXT.COD_BUSUN = NVL(:B2 , ENEXT.COD_BUSUN)
    AND ENEXT.COD_CAL = NVL(COD_CAL, ENEXT.COD_CAL) AND ENEXT.NUM_PRSN_EMPLY =
    NVL(:B1 , ENEXT.NUM_PRSN_EMPLY) AND ENEXT.COD_SHFT IN (SELECT
    SHFTBL.COD_SHTAB FROM AAC_SHIFT_TABLES SHFTBL WHERE
    SHFTBL.LKP_CAT_SHFT_SHTAB = 1) AND ENEXT.DAT_CALDE NOT IN (SELECT ABN.DAT
    FROM APPS.AAC_EMPL_EN_EX_ABNORMAL_VIW ABN WHERE ABN.PRSN =
    ENEXT.NUM_PRSN_EMPLY AND ABN.DAT BETWEEN :B6 AND :B5 ) AND ENEXT.DAT_CALDE
    IN (SELECT EMPENEXT.DAT_STR_SHFT_ENEXT FROM AAC.AAC_EMPLOYEE_ENTRY_EXITS
    EMPENEXT WHERE EMPENEXT.EMPLY_NUM_PRSN_EMPLY = EMPL.NUM_PRSN_EMPLY AND
    EMPENEXT.DAT_STR_SHFT_ENEXT BETWEEN :B6 AND :B5 AND
    EMPENEXT.LKP_FLG_STA_ENEXT <> 3) ORDER BY ENEXT.NUM_PRSN_EMPLY,
    ENEXT.DAT_CALDE
    call count cpu elapsed disk query current rows
    Parse 2 0.00 0.00 0 0 0 0
    Execute 2 0.00 0.00 0 0 0 0
    Fetch 2 40.45 40.30 306 17107740 0 24
    total 6 40.45 40.30 306 17107740 0 24
    what is wrong in my query?
    why it take long time?

    user13344656 wrote:
    what is wrong in my query?
    why it take long time?See PL/SQL forum FAQ
    https://forums.oracle.com/forums/ann.jspa?annID=1535
    *3. How to improve the performance of my query? / My query is running slow.*
    SQL and PL/SQL FAQ
    For instructions on what information to post an how to format it.

  • Select query takes long time....

    Hi Experts,
    I am using a select query in which inspection lot is in another table and order no. is in another table. this select query taking very long time, what is the problem in this query ? Pl. guide us.
    select bPRUEFLOS bMBLNR bCPUDT aAUFNR amatnr aLGORT a~bwart
    amenge aummat asgtxt axauto
    into corresponding fields of table itab
    *into table itab
    from mseg as a inner join qamb as b
    on amblnr = bmblnr
    and azeile = bzeile
    where b~PRUEFLOS in insp
    and  b~cpudt in date1
    and b~typ = '3'
    and a~bwart = '321'
    and a~aufnr in aufnr1.
    Yusuf

    hi
    instead of using 'move to corresponding of itab'  fields use  'into table itab'.....
    coz......if u use move to corresponding it will search for all the appropriate fields then it will place u r data........instead of that declare apprpiate internal table and use 'into table itab'.
    and one more thing dont use joins ......coz joins will decrease u r performance .....so instead of that use 'for all entries' ....and mention all the key fields in where condition ........
    ok
    reward points for helpful answers

  • Report takes long time for few records

    hi frends,
    I m facing one problem with my Web based erp application which is developed in .net , in my application when i open the  report from my applicaiton , in my temp folder there one file gets created name is "rpt conmgr cache"
    bcoz of this for few records also my report takes too much time and opens very slow and it takes long time, and it happens in some of the reports only , other reports are working cool and its not creating any file in temp folder,,, so can u guide me whats this file and what can be the solution for it,
    Thanks
    Mithun

    hi sabhajit,
    i have already checked the sql query it is taking less then seconds.
    any other steps u want me to check then pls let me know?
    thanks mithun

  • MVIEW refresh takes long time

    Materialized view takes long time to refresh but when i tried select & insert into table it's very fast.
    i executed SQL and it takes ust 1min ( total rows is 447 )
    but while i refresh the MVIEW it takes 1.5 hrs ( total rows is 447 )
    MVIEW configration :-
    CREATE MATERIALIZED VIEW EVAL.EVALSEARCH_PRV_LWC
    TABLESPACE EVAL_T_S_01
    NOCACHE
    NOLOGGING
    NOCOMPRESS
    NOPARALLEL
    BUILD DEFERRED
    REFRESH FORCE ON DEMAND
    WITH PRIMARY KEY
    Not sure why so much diffrence

    infant_raj wrote:
    Materialized view takes long time to refresh but when i tried select & insert into table it's very fast.
    i executed SQL and it takes ust 1min ( total rows is 447 )
    but while i refresh the MVIEW it takes 1.5 hrs ( total rows is 447 )A SELECT does a consistent read.
    A MV refresh does that and also writes database data.
    These are not the same thing and cannot be directly compared.
    So instead of pointing at the SELECT execution time and asking why the MV refresh is not as fast, look instead WHAT the refresh is doing and HOW it is doing that.
    Is the execution plan sane? What events are the top ones for the MV refresh? What are the wait states that contributes most to the processing time of the refresh?
    You cannot use the SELECT statement's execution time as a direct comparison metric. The work done by the refresh is more than the work done by the SELECT. You need to determine exactly what work is done by the refresh and whether that work is done in a reasonable time, and how other sessions are impacting the refresh (it could very well be blocked by another session).

Maybe you are looking for