Please guide to improve the performance of XML column reading query.

Hi Experts,
The below query is taking 45 seconds to return 170 records.
Due to selecting XMLTYPE column in query.
select *
from RANGE where WSNO = 3
order by PREFERENCE desc;
The total number of records in the table is 1060.
Even it's a very small table why it's taking 45 seconds.
Can anybody please help me on how to get the output in 2 to 3 seconds.
I want all the columns from the table.
The problem only with REST column XMLTYPE.
If I am not selecting this column I am getting output in 1 to 2 seconds.
I am posting the execution plan and DDL for table and index.
PLAN_TABLE_OUTPUT
Plan hash value: 3593186720
| SNO  | Operation                    | EMPNAME                   | Rows  | Bytes | Cost (%CPU)| Time     |
|   0 | SELECT STATEMENT             |                        |    31 | 23281 |    21   (5)| 00:00:01 |
|   1 |  SORT ORDER BY               |                        |    31 | 23281 |    21   (5)| 00:00:01 |
|   2 |   TABLE ACCESS BY INDEX ROWID | RANGE                 |    31 | 23281 |    20   (0)| 00:00:01 |
|*  3 |    INDEX RANGE SCAN          | INDX_WSNO              |    31 |       |     1   (0)| 00:00:01 |
Predicate Information (SNOentified by operation SNO):
   3 - access("WSNO"=3)
CREATE TABLE RANGE
  SNO                              NUMBER,
  BUSNO                            NUMBER,
  EMPNAME                          NVARCHAR2(64),
  PREFERENCE                       NUMBER,
  TSNO                             NUMBER,
  MEMBER                          CHAR(1 CHAR) ,
  EQU                             CHAR(1 CHAR) ,
  REMAIL                          CHAR(1 CHAR) ,
  SSR                             CHAR(1 CHAR) ,
  SUB                             CHAR(1 CHAR) ,
  SPN                             CHAR(1 CHAR) ,
  SEMPNAME                        NVARCHAR2(128),
  FVL                             NUMBER(32),
  TVL                             NUMBER(32),
  ISD                             CHAR(1 CHAR),
  CHANGED                         NVARCHAR2(64),
  CDATE                           TIMESTAMP(6) ,
  UDBY                            NVARCHAR2(64),
  UDATE                           TIMESTAMP(6),
  LSTU                            CLOB,
  WSNO                            NUMBER,
  ASTN                            CHAR(1 CHAR),
  ASTNPL                          CHAR(1 CHAR),
  AVAF                            CHAR(1 CHAR),
  REST                            SYS.XMLTYPE
TABLESPACE USERS
PCTUSED    0
PCTFREE    10
INITRANS   11
MAXTRANS   255
STORAGE    (
            INITIAL          64K
            NEXT             1M
            MINEXTENTS       1
            MAXEXTENTS       UNLIMITED
            PCTINCREASE      0
            BUFFER_POOL      DEFAULT
XMLTYPE REST STORE AS CLOB
      ( TABLESPACE  USERS
        ENABLE      STORAGE IN ROW
        CHUNK       8192
        PCTVERSION  10
        NOCACHE
        INDEX       (
          TABLESPACE USERS
          STORAGE    (
                      INITIAL          64K
                      NEXT             1
                      MINEXTENTS       1
                      MAXEXTENTS       UNLIMITED
                      PCTINCREASE      0
                      BUFFER_POOL      DEFAULT
        STORAGE    (
                    INITIAL          64K
                    NEXT             1M
                    MINEXTENTS       1
                    MAXEXTENTS       UNLIMITED
                    PCTINCREASE      0
                    BUFFER_POOL      DEFAULT
  LOB (LSTU) STORE AS
      ( TABLESPACE  USERS
        ENABLE      STORAGE IN ROW
        CHUNK       8192
        RETENTION
        NOCACHE
        INDEX       (
          TABLESPACE USERS
          STORAGE    (
                      INITIAL          64K
                      NEXT             1
                      MINEXTENTS       1
                      MAXEXTENTS       UNLIMITED
                      PCTINCREASE      0
                      BUFFER_POOL      DEFAULT
        STORAGE    (
                    INITIAL          64K
                    NEXT             1M
                    MINEXTENTS       1
                    MAXEXTENTS       UNLIMITED
                    PCTINCREASE      0
                    BUFFER_POOL      DEFAULT
NOCACHE
NOPARALLEL
MONITORING;
CREATE INDEX INDX_WSNO ON RANGE(WSNO);
CREATE UNIQUE INDEX RULE_EMPNAME ON RANGE(BUSNO, EMPNAME);
Please help me how to improve the performance of this query.
Thanks.

Can you try something like this and check if its faster? (this is just my guess as I dont have your data )
SELECT SNO,
       BUSNO,
       EMPNAME,
       PREFERENCE,
       TSNO,
       MEMBER,
       EQU,
       REMAIL,
       SSR,
       SUB,
       SPN,
       SEMPNAME,
       FVL,
       TVL,
       ISD,
       CHANGED,
       CDATE,
       UDBY,
       UDATE,
       LSTU,
       WSNO,
       ASTN,
       ASTNPL,
       AVAF,
       xmltype.getclobval (rest) rest
  FROM RANGE
WHERE wsno = 3
order by PREFERENCE desc;
Cheers,
Manik.

Similar Messages

  • Index don't improve the performance

    Hello everyone,
    I've a problem on improving the performance of XMLType Column. In fact, I've created a table with tow column a Number column and a XMLType column and found out that the retreival time is quite unexceptal for the following SQL Statement:
    Select id, extractValue(data, '/requestor/name') From
    requestor Where extractValue(data, '/requestor/name')
    = 'Req1640'
    So I have created an Index like this:
    create index req_name_index on requestor
    extractValue(data, '/requestor/name')
    but it don't improve the performance.
    What's wrong?
    Thanks

    Hi David,
    Once you had defined the 2 entries for the Browsing Index, have you rebuilt the indexes for the database ?
    You can either use db2index or export and re-import the data.
    Regards,
    Ludovic.

  • Please help me how to improve the performance of this query further.

    Hi All,
    Please help me how to improve the performance of this query further.
    Thanks.

    Hi,
    this is not your first SQL tuning request in this community -- you really should learn how to obtain performance diagnostics.
    The information you posted is not nearly enough to even start troubleshooting the query -- you haven't specified elapsed time, I/O, or the actual number of rows the query returns.
    The only piece of information we have is saying that your query executes within a second. If we believe this, then your query doesn't need tuning. If we don't, then we throw it away
    and we're left with nothing.
    Start by reading this blog post: Kyle Hailey » Power of DISPLAY_CURSOR
    and applying this knowledge to your case.
    Best regards,
      Nikolay

  • Need suggestions on improving the performance end to end

    I referred following links and as many as 25 previous posts before posting this question.
    https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/10b54994-f569-2a10-ad8f-cf5c68a9447c
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/402fae48-0601-0010-3088-85c46a236f50
    https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/e0068bc1-6f8c-2a10-52bb-c6ee3562feb2
    /people/boris.zarske/blog/2007/06/13/sizing-a-system-for-the-system-landscape-directory-of-sap-netweaver
    I have some queries related to improving the performance of a scenario in my landscape.
    Scenario : IDOC-SOAP (Synchronous with BPM)
    The mapping is simple with 3 fld direct mapping.
    Works grt with no problem in normal cases for one message transfer.
    But initial load ( when we put it in new system, the scenario generates erros if we send more than 23 IDOCs at a time)
    I have decided to perform the following to solve it.
    /people/william.li/blog/2008/03/07/step-by-step-guide-in-processing-high-volume-messages-using-pi-71s-message-packaging
    Will it help me because its a IDOC sync scenario.
    What can I do to improve the performance of this scenario?
    Please suggest me good suggestions to improve the performance
    Please do list me out points that I have to perform (for a sync scenario with BPM) as I am already confused watching lots of blogs posts.
    Nikhil.

    do you think that the performance tuning that I mentioned in the link will hold good with sync scenarios?
    i dont think so.....in this scenario the async mesg processing is made to wait
    from the blog:
    As you can see, for the 1st minute, all the messages are waiting to be processed. After 60 seconds,
    the packages will be created and processed. There is no change to the monitoring of each of the
    individual messages in SXI_MONITOR.
    ....but if you make a sync scenario wait....then probably you may run into the risk of blocking the Queues.......
    If this is going to be in production then i would have been more careful...becoz firstly it is BPM....then synchronous BPM.....then a processing wait......normally do not try to make the BPM processing wait...my small suggestion

  • How to improve the performance of adobe forms

    Hi,
    Please give me some suggestions as to how to improve the performance of adobe form?
    Right now when I' am doing user events it is working fine for first 6 or 7 user events. From the next
    one it is hanging.
    I read about Wizard form design approach, how to use the same here.
    Thanks,
    Aravind

    Hi Otto,
    The form is created using HCM forms and processes. I' am performing user events in the form.
    User events will doa round trip, in which form data will be sent to backend SAP system. Processing will
    happen on the ABAP side and result will appear on the form. First 6 or 7 user events works correctly,
    the result is appearing on the form. Around 8 or 9th one, the wait symbol appears and the form is not
    re-rendered. The form is of size 6 pages. The issue is not coming with form of size 1 page.
    I was reading ways to improve performance during re-rendering given below.
    http://www.adobe.com/devnet/livecycle/articles/DynamicInteractiveFormPerformance.pdf
    It talks about wizard form design approach. But in SFP transaction, I am not seeing any kind of wizard.
    Let me know if you need further details.
    Thanks,
    Aravind

  • How to Improve the performance in Variable Selection Screen.

    Hi,
    In Query Level we have Variable " User entry Defalt Valu". User want select particular value when he press "F4" it's take hours time how to improve the performance in Varaible Selection Screen.
    Thanks in Advance.
    Regards,
    Venkat.

    Dear Venkat.
    You please try the following steps:
    1. Say the InfoObject is 0EMPLOYEE against which you have created the variable, which user is trying to select value against, when they execute the report.
    2. Goto RSA1-> InfoObject tab-> Select InfoObject 0EMPLOYEE.
    3. Selcet the following options:
       Query Execution Filter Val. Selectn  -  'Only Posted Value for Navigation'
       Filter Value Repr. At Query Exec. -      'Selector Box Without Values'
    Please let me know if there is any more issue. Feel free to raise further concern
    Thnx,
    Sukdev K

  • To improve the performance of the extractor

    Hi Team,
    Currently there is one dataload which is taking 48hours to extract data from R/3 System to BI. It is based on infoset query.
    The extractor uses the standard LDB : PNP, The database driver for this LDB is SAPDBPNP.
    The extractor is based on PA0008 infotype.
    1 tricky part of this code is that the values are not stored in the PA0008 table, but these are dynamically calculated during the infoset extract.
    Could you please provide some inputs in improving the performance.
    Thanks in advance.
    Sunil Kumar.

    Since its dynamically calculated during the infoset extract, obviously it would go longer time. Because it has to calculate those many times as the no.of PERNR (in IT8).
    If possible try to move those calculations to Transfer / Update Rules level.
    OR
    If its a non-delta datasource, try to add more infopackages (with PERNR selections) to this datasource, run them in parallel in process chain.

  • How to improve the performance of policy import process

    Hello OES 10g Experts,
    I have an application specific policy XML of OES 10g. While importing it to OES using policyIX.sh command, the process is taking around 3.5 hrs in DEV servers. The policy XML size is around 2 MB. However there are other applications which are being imported in less than 30 mins.
    Perhaps it is due to the size of the XML, the policy import process is taking huge time which may not be viable in production systems. But I would like to know if there is a way to improve the performance of import process. The command syntax I am using is
    ./policyIX.sh -import -disableTransaction config.xml policy.xml
    I have tried removing the parameter -disableTransaction but there is no performance improvement.
    Appreciate any inputs.
    Thanks
    Mahendra.

    Go through following link:-
    http://docs.oracle.com/cd/E21764_01/doc.1111/e14316/org_mangmnt.htm#OMUSG2741

  • How to improve the performance of insert statement.

    Hi All,
    I have one procedure and it inserts 40 million records into one table. As my current method taking long time to accomplish the task, Is there any mechanism to improve the performance
    Thanks in Advance.

    > Thanks for pointing out my mistake Billy :)
    It is a common misconception it seems - that Oracle PQ is only useful for multi CPU platforms. I have seen it mentioned numerous times since the Oracle 7 OPS days in the mid 90's.
    > Edit: Could you please highlight which operations
    benefit from a multi-cpu machine?
    More CPUs increase the CPU capacity of the platform (and not speed). Allows it to run more processes.
    So very simplistically - on a single CPU box you find only sufficient CPU capacity (free CPU time) to run a parallel degree of 2 (i.e. 2 PQs). On a 4 CPU box, you may sufficient capacity for a degree of 10.
    But there are some catches here.
    Oracle PQ is specifically used for I/O sharing. Instead of a single process doing all the I/O, the I/O is shared amongst a bunch of PQ processes.
    The real bottle neck here is actually the size of the pipe to the disk.
    Simple example: You may have sufficient CPU capacity to run 20 PQs. But the I/O pipe will be seriously hammered as the pipe can only do a 1000 IOs/sec, and these 20 PQs are trying to push 10,000 IOs/sec.
    Another catch is that there are overheads when using SMP (symetrical multi processing). Again, very basically: as only a single CPU can for example access a specific piece of memory, two processes running on two different CPUs can cause "contention" when trying to access this memory (e.g. a typical piece of shared memory).
    So having two related processes running on two different CPUs can be in fact slower than having both related processes running on the same CPU.
    This is quite noticeable on Windows NT/2000/XP kernel for example. Windows will load the 1st CPU close to capacity, before spilling across to the 2nd CPU. It is the norm to see the 1st CPU with high usage and the 2nd CPU running almost idle. (something that seems to have PC gamers confused in recent times when using "high-end" dual core machines and not understanding why the 2nd CPU does not seem to be used)
    Bottom line. Multi-CPU platforms provide more processing capacity for running PQ than a single CPU platform. But a single CPU is capable of running PQ if there is capacity (which is often the case).

  • How to improve the performance of the abap program

    hi all,
    I have created an abap program. And it taking long time since the number of records are more. And can anyone let me know how to improve the performance of my abap program.
    Using se30 and st05 transaction.
    can anyone help me out step by step
    regds
    haritha

    Hi Haritha,
    ->Run Any program using SE30 (performance analysis)
    Note: Click on the Tips & Tricks button from SE30 to get performance improving tips.
    Using this you can improve the performance by analyzing your code part by part.
    ->To turn runtim analysis on within ABAP code insert the following code
    SET RUN TIME ANALYZER ON.
    ->To turn runtim analysis off within ABAP code insert the following code
    SET RUN TIME ANALYZER OFF.
    ->Always check the driver internal tables is not empty, while using FOR ALL ENTRIES
    ->Avoid for all entries in JOINS
    ->Try to avoid joins and use FOR ALL ENTRIES.
    ->Try to restrict the joins to 1 level only ie only for tables
    ->Avoid using Select *.
    ->Avoid having multiple Selects from the same table in the same object.
    ->Try to minimize the number of variables to save memory.
    ->The sequence of fields in 'where clause' must be as per primary/secondary index ( if any)
    ->Avoid creation of index as far as possible
    ->Avoid operators like <>, > , < & like % in where clause conditions
    ->Avoid select/select single statements in loops.
    ->Try to use 'binary search' in READ internal table. -->Ensure table is sorted before using BINARY SEARCH.
    ->Avoid using aggregate functions (SUM, MAX etc) in selects ( GROUP BY , HAVING,)
    ->Avoid using ORDER BY in selects
    ->Avoid Nested Selects
    ->Avoid Nested Loops of Internal Tables
    ->Try to use FIELD SYMBOLS.
    ->Try to avoid into Corresponding Fields of
    ->Avoid using Select Distinct, Use DELETE ADJACENT
    Check the following Links
    Re: performance tuning
    Re: Performance tuning of program
    http://www.sapgenie.com/abap/performance.htm
    http://www.thespot4sap.com/Articles/SAPABAPPerformanceTuning_PerformanceAnalysisTools.asp
    check the below link
    http://www.sap-img.com/abap/performance-tuning-for-data-selection-statement.htm
    See the following link if it's any help:
    http://www.thespot4sap.com/Articles/SAPABAPPerformanceTuning_PerformanceAnalysisTools.asp
    Check also http://service.sap.com/performance
    and
    books like
    http://www.sap-press.com/product.cfm?account=&product=H951
    http://www.sap-press.com/product.cfm?account=&product=H973
    http://www.sap-img.com/abap/more-than-100-abap-interview-faqs.htm
    http://www.thespot4sap.com/Articles/SAPABAPPerformanceTuning_PerformanceAnalysisTools.asp
    Performance tuning for Data Selection Statement
    http://www.sap-img.com/abap/performance-tuning-for-data-selection-statement.htm
    Debugger
    http://help.sap.com/saphelp_47x200/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    http://www.cba.nau.edu/haney-j/CIS497/Assignments/Debugging.doc
    http://help.sap.com/saphelp_erp2005/helpdata/en/b3/d322540c3beb4ba53795784eebb680/frameset.htm
    Run Time Analyser
    http://help.sap.com/saphelp_47x200/helpdata/en/c6/617cafe68c11d2b2ab080009b43351/content.htm
    SQL trace
    http://help.sap.com/saphelp_47x200/helpdata/en/d1/801f7c454211d189710000e8322d00/content.htm
    CATT - Computer Aided Testing Too
    http://help.sap.com/saphelp_47x200/helpdata/en/b3/410b37233f7c6fe10000009b38f936/frameset.htm
    Test Workbench
    http://help.sap.com/saphelp_47x200/helpdata/en/a8/157235d0fa8742e10000009b38f889/frameset.htm
    Coverage Analyser
    http://help.sap.com/saphelp_47x200/helpdata/en/c7/af9a79061a11d4b3d4080009b43351/content.htm
    Runtime Monitor
    http://help.sap.com/saphelp_47x200/helpdata/en/b5/fa121cc15911d5993d00508b6b8b11/content.htm
    Memory Inspector
    http://help.sap.com/saphelp_47x200/helpdata/en/a2/e5fc84cc87964cb2c29f584152d74e/content.htm
    ECATT - Extended Computer Aided testing tool.
    http://help.sap.com/saphelp_47x200/helpdata/en/20/e81c3b84e65e7be10000000a11402f/frameset.htm
    Just refer to these links...
    performance
    Performance
    Performance Guide
    performance issues...
    Performance Tuning
    Performance issues
    performance tuning
    performance tuning
    You can go to the transaction SE30 to have the runtime analysis of your program.Also try the transaction SCI , which is SAP Code Inspector.
    edited by,
    Naveenan

  • How to improve the performance in AM level

    Hi,
    I am using Jdeveloper 11.1.1.2.0 and weblogic server 10.3.2.
    How to improve the performance in AM level.
    Actually i have approx 10 lacs Data but when search the record then it is taking more time.
    I have following the link..
    http://www.gebs.ro/blog/oracle/adf-view-object-performance-tuning-analysis/
    but there is no effect in the performance level for seaching.
    So please help me ..
    Thanks
    Anup

    Hi Timo,
    In search page,i m giving empId and click on search button then to execute query it is taking more time.I have override the VOImpl executeQuery(). then it is taking more time
    @Override
    public void executeQuery() {
    setNamedWhereClauseParam("bind_draft", "D");
    setNamedWhereClauseParam("bind_complete","%");
    setNamedWhereClauseParam("bind_reject","%");
    setNamedWhereClauseParam("bind_approve","A");
    setNamedWhereClauseParam("bind_review","R");
    super.executeQuery();
    this method super.executeQuery() is calling and after 5 minutes heap space is comming on cosole as well as page also.
    Thanks
    Anup

  • Inner Join. How to improve the performance of inner join query

    Inner Join. How to improve the performance of inner join query.
    Query is :
    select f1~ablbelnr
             f1~gernr
             f1~equnr
             f1~zwnummer
             f1~adat
             f1~atim
             f1~v_zwstand
             f1~n_zwstand
             f1~aktiv
             f1~adatsoll
             f1~pruefzahl
             f1~ablstat
             f1~pruefpkt
             f1~popcode
             f1~erdat
             f1~istablart
             f2~anlage
             f2~ablesgr
             f2~abrdats
             f2~ableinh
                from eabl as f1
                inner join eablg as f2
                on f1ablbelnr = f2ablbelnr
                into corresponding fields of table it_list
                where f1~ablstat in s_mrstat
                %_HINTS ORACLE 'USE_NL (T_00 T_01) index(T_01 "EABLG~0")'.
    I wanted to modify the query, since its taking lot of time to load the data.
    Please suggest : -
    Treat this is very urgent.

    Hi Shyamal,
    In your program , you are using "into corresponding fields of ".
    Try not to use this addition in your select query.
    Instead, just use "into table it_list".
    As an example,
    Just give a normal query using "into corresponding fields of" in a program. Now go to se30 ( Runtime analysis), and give the program name and execute it .
    Now if you click on Analyze button , you can see, the analysis given for the query.The one given in "Red" line informs you that you need to find for alternate methods.
    On the other hand, if you are using "into table itab", it will give you an entirely different analysis.
    So try not to give "into corresponding fields" in your query.
    Regards,
    SP.

  • Improve the Performance of Loops

    Has anyone read "Improve the Performance of Loops" on http://archive.devx.com/free/tips/tipview.asp?content_id=3945 ?
    If so, would you agree that what's written there is absolute b.....t?
    He claims that decreasing the counter improves the performance and tries to prove it with the program:
    for (int i=0,n=Integer.MAX_VALUE;i<n;i++){
    a =-a;
    // is slower than
    long midTime =System.currentTimeMillis();
    for (int i=Integer.MAX_VALUE-1 ; i>=0 ; i--){
    a =-a;
    }The result is pretty impressive:
    Increasing Loop:4891
    Decreasing Loop:3781
    The only stupid thing is that:
    1. if you run it more times you get
    Increasing Loop:4891
    Decreasing Loop:3781
    Increasing Loop:3782
    Decreasing Loop:3796
    Increasing Loop:3891
    Decreasing Loop:3891
    Increasing Loop:3828
    Decreasing Loop:3937
    Increasing Loop:3891
    Decreasing Loop:3906
    Increasing Loop:3860
    Decreasing Loop:3937
    Increasing Loop:3891
    Decreasing Loop:3906
    So you can see that the performance is worse for decreasing loops after hotspot warmed up.
    2. If you run it with -server, you'll even get:
    Increasing Loop:16
    Decreasing Loop:0
    Increasing Loop:0
    Decreasing Loop:0
    Increasing Loop:0
    Decreasing Loop:0
    Increasing Loop:0
    Decreasing Loop:0
    Increasing Loop:0
    Decreasing Loop:0
    Increasing Loop:0
    Decreasing Loop:0
    Increasing Loop:0
    Decreasing Loop:0
    This shows that hotspot sever is much more clever than some programmers.
    Even if you change the code to do something bit better like
        public TimeLoop() {
            int a = 2,b=2;
            long startTime = System.currentTimeMillis();
            for (int i = 0, n = Integer.MAX_VALUE; i < n; i++) {
                a ^= i;
            long midTime = System.currentTimeMillis();
            for (int i = Integer.MAX_VALUE - 1; i >= 0; i--) {
                   a ^= i;
            long endTime = System.currentTimeMillis();
            System.out.println("Increasing Loop:" + (midTime - startTime));
            System.out.println("Decreasing Loop:" + (endTime - midTime));
              System.out.println("a="+a+" b="+b);      // Hotspot must perform _some_ kind of calculation to print this          
        }You'll find that it doesn't really matter whether you're xoring in increasing or decreasing order.
    For -client:
    Increasing Loop:296
    Decreasing Loop:297
    a=2 b=2
    Increasing Loop:297
    Decreasing Loop:281
    a=2 b=2
    Increasing Loop:297
    Decreasing Loop:297
    a=2 b=2
    For -server:
    Increasing Loop:141
    Decreasing Loop:156
    a=2 b=2
    Increasing Loop:141
    Decreasing Loop:141
    a=2 b=2
    Increasing Loop:140
    Decreasing Loop:156
    a=2 b=2
    (Last three runs for each).
    And I don't believe that accessing array.length is slower than storing the length in an int and comparing against that int!
    Please let's just stop posting silly perfomance tuning tips!

    Well, you can always look at the bytecode produced. I wrote two little classes:public class t {
      public static void main ( String[] args ) {
        int a = 0;
        for (int i=0,n=Integer.MAX_VALUE;i<n;i++){ a =-a; }
    }andpublic class t1 {
      public static void main ( String[] args ) {
        int a = 0;
        for (int i=Integer.MAX_VALUE-1 ; i>=0 ; i--){ a =-a; }
    }And here's the bytecode for their main() methods. (Extra/different bytecodes in "t" are marked):t: (incrementing)Method void main(java.lang.String[])
       0 iconst_0
       1 istore_1
    ==>2 iconst_0
       3 istore_2
       4 ldc #2 <Integer 2147483647>
       6 istore_3
       7 goto 16
      10 iload_1
      11 ineg
      12 istore_1
      13 iinc 2 1
      16 iload_2
    ==>17 iload_3
    ==>18 if_icmplt 10
      21 return
    t1: (decrementing)
    Method void main(java.lang.String[])
       0 iconst_0
       1 istore_1
       2 ldc #2 <Integer 2147483646>
       4 istore_2
       5 goto 14
       8 iload_1
       9 ineg
      10 istore_1
      11 iinc 2 -1
      14 iload_2
      15 ifge 8
      18 return The decrementing code does use fewer bytecodes to do its thing.
    However, as someone pointed out - once Hotspot gets involved, all bets are off. And as someone else pointed out, if the body of the loop does nearly anything at all, the 2-bytecode-difference is going to get completely swamped.
    In general, this is the kind of micro-optimizing that I'd ignore completely...
    Grant

  • Options to improve the performance of the Job

    Hi Team,
    As part of the CRM Upgrade requirement, we are planning to use Account Life cycle functionality to reflect the status of an account.
    As per the SAP recommendations( Note 1113330) we are currently executing the program CRM_BUPA_USERSTATUS_CONV2ROLE to convert user status master data to BP roles. We have noticed that this program is taking more time even when we run this for single business partner. We are trying to explore the options on how to improve the performance of the job. Incase if anyone have done this kind of exercise in any of their previous assignments or have information on this, request to provide your feedback on the below points.
    1) Total Volume of Customer Master Data
    2) How many records did we consider for one execution of the conversion program
    3) How much time did it toke for one execution ?Did we do any performance tuning
    4) When we are running the program in back ground mode..we are not getting the spool
    showing the log information. Was there any custom report developed to view the log when
    we execute the program in background mode..if so can you share us the technical details
    6) Any information on how many work processors that were available for executing the jobs 
    Appreciate your help.
    Regards,
    Varun

    Hello Udaya ,
    Could you please tryy providing a range of BPs as per note 1121015? This can help in improving the performance .
    Thanks & regards,
    Krishnen

  • Gather Schema Statistics improve the performance of the R12 application?

    Hi All,
    If we run “Gather Schema Statistics” program, it will improve the performance of the R12 application?
    Platform Linux and DB version 10.2.0.4.
    Thanks & Regards,
    Tharun

    Hi Tharun,
    If we ruer n “Gather Schema Statistics” program, it will improve the performance of the R12 application?
    Yes, it will speed up as it ensures to have an up to date statistics.
    Please refer notes:
    Concurrent Processing - How To Gather Statistics On Oracle Applications Release 11i and/or Release 12 - Concurrent Process,Temp Tables, Manually [ID 419728.1]
    How Often Should Gather Schema Statistics Program be Run? [ID 168136.1]
    Why Stats Gather?
    Stats gathering must be set as a routine job and is recommended to be scheduled. Even though this program is available from the fronted in the form of submitting a concurrent program basically it performs a DB level enhancement and ensures that you have an up to date optimizer statistics.Because the objects in a database can be constantly changing, statistics must be regularly updated so that they accurately describe these database objects.
    For indepth understand as to why it should be run, please refer doc:
    Managing Optimizer Statistics
    Thanks &
    Best Regards,

Maybe you are looking for

  • Connecting HP Laserjet 1010HB with Macbook Pro via D-Link Network!?

    Good evening, I have a MacBook Pro and I want to be able to print via WiFi. The Printer is hosted by a Windows Computer via D-Link Router Network My sister who has a Windows Laptop is able to print. I read about Bonjour but this seems to be a softwar

  • Unable to uninstall Windows 7 on Java XP

    I am trying to uninstall Java 7 Update 6 on Windows XP and I get a message about the feature I am trying to use is on a network resource that is unavailable after a new install of XP from the MSDN Platinum download service. How is a consumer supposed

  • Workforce Planning in Planning and Budgeting Cloud Servie

    Hi Experts, Does Oracle Planning and Budgeting Cloud Service (PBCS) have Pre-build modules Workforce Planning, Capital Asset Planning and Project Finance Planning. According to my understanding PBCS doesn't have any pre-build modules. I am not sure w

  • Mac Pro running very slow

    HI EVERYONE, I HAVE MACPRO INTEL 7 8GB RAM 750GB. I tried to upgrade the system to Mac OS 10.9 maverick and I am having trouble to connect to the home wi if as it is very inconsistent and turns itself on and off every 2/3 minutes. Also I guess I am h

  • Files Open as Smart Objects

    I am in the process of trying to get better with CS5. For some reason, all my files seem to open as Smart Objects. When the file opens, it is a RAW file, there is no 'lock' on the background layer. How do I get a file to open in a 'normal' way. Thank