BPS variable exit takes more execution time

Hi,
    I am having a BPS variable of type exit in the planning level and it is taking very long time to execute the layout even though my planning cube is having very little data.
Can any one tell me how to reduce the excution time of the layout .
Thanks,
Ramkumar.

Hi Ravi,
        I excuted the FM in se37 with a SQL Trace and it was working fine . there are no expensive statements .
The same FM performs well if the output record count is less say 10, but taking more time when the output record count is more say 8000.
Is there any way to increase the performance of the BPS layout . or do i need to apply any notes for it.
if any one faced the same problum kindly let me know how to resolve this . your help is greatly appreciated.
Thanks
Ramkumar

Similar Messages

  • BPS variables exit F4 help

    Hi,
       I am having a BPS variable exit which is listing all the records from the master data table in the F4 help screen but  i want to see only those values which are populated by my exit .
    Did any one faced the same problum? Do we have a note or patch to fix this.
    Thanks,
    Ramkumar

    Hi Ramkumar,
    Check the ABAP code behind the variable.Make sure that it is fetching the right records based on the logc in the code.Check the select statement in the ABAP.
    Debug the code and find out if its fetchin the right values into the export parameter  ETO_CHARSEL.
    hope this helps.
    regards
    Sai Vishnubhatla.

  • Transaction takes more database time

    Hi friend,
    Today morning one user excute transaction CK40N shows more time at the database level.It impacts on performance of our production system.Now i want to investigate why this transaction takes more database time .
    I want to compare with last 2 months database time taken  by excuting this transaction (CK40N) in the same date and time.
    i tried but i am unable   to get i checked in st03n,stad.
    can  any body can help me how to find out.
    Best Regards,
    kiranchaitanya.
    mine environment:-
    ECC6.0,
    IBM-AIX-5.3
    ORACLE-10.0.2.0.2

    Dear Kiranchaitanya
    Regardless of the issue I recommend implementing BR*Tools 7.10 and SAP note [Note 1020260 - Delivery of Oracle statistics|https://service.sap.com/sap/support/notes/1020260] if not yet performed.
    Check the following:
    - Oracle statistics are created daily
    - Oracle system statistics are created quarterly (or after specific interventions)
    - Oracle dictionary statistics are created quarterly (or after specific interventions)
    Check your performance details of Oracle (hit cache ratio and so on) to ensure those are correct in DB02 under Performance Overview.
    To check the transaction in ST03N go into expert mode and on the left pane under "workload" you can compare by week for example
    double-click the week of which you want data. Next go the lower left pane, there you need to db-click on "Standard" under Analysis Views --> Transaction Profile.
    Next find or the list so you have your transaction displayed in the list on the right pane.
    Repeat these steps for other weeks and compare the data.
    Can you tell me how many % of the response time is database time (once you have the transaction on the right pane in ST03N with statistical data, go
    to the third tab there called "parts of response time" and check the %DB Time column) ?
    Kind regards
    Tom

  • Bind variable code takes more time to complete?

    Hello, My database is oracle11g.
    I have same plsql code and first one is without bind variable and second one is with bind variable. Usually, bind variable should take less time. But here
    the bind variable takes more time than the regular code... Can any one please explain why?
    SQL> alter system flush shared_pool;
    System altered.
    SQL> declare
    2 cursor c1 is select * from emp where rownum < 50;
    3 l_start NUMBER DEFAULT DBMS_UTILITY.GET_TIME;
    4 v_cnt number;
    5 begin
    6 for i in c1 loop
    7 SELECT count(*) into v_cnt
    8 FROM rate
    9 WHERE rate_id IN (SELECT rate_id
    10 FROM ratedetail
    11 WHERE benefit_id = i.benefit_id)
    12 AND effective_date =
    13 TO_DATE ('2011-01-23 00:00:00', 'yyyy-MM-dd HH24:MI:SS')
    14 AND rate_type_id = 1;
    15 end loop;
    16 DBMS_OUTPUT.PUT_LINE('total minutes....'||ROUND(ROUND((DBMS_UTILITY.GET_TIME - l_start)/100, 2)
    /60,3));
    17 end;
    18 /
    total minutes.....06
    PL/SQL procedure successfully completed.
    SQL> alter system flush shared_pool;
    System altered.
    SQL>
    SQL> declare
    2 cursor c1 is select benefit_id from emp where rownum < 50;
    3 l_start NUMBER DEFAULT DBMS_UTILITY.GET_TIME;
    4 v_cnt number;
    5 begin
    6 for i in c1 loop
    7 execute immediate 'SELECT count(*)
    8 FROM rate
    9 WHERE rate_id IN (SELECT rate_id
    10 FROM ratedetail
    11 WHERE benefit_id = :x)
    12 AND effective_date = trunc(sysdate)-202
    13 AND rate_type_id = 1'
    14 into v_cnt using i.benefit_id;
    15 end loop;
    16 DBMS_OUTPUT.PUT_LINE('total minutes....'||ROUND(ROUND((DBMS_UTILITY.GET_TIME - l_start)/100, 2)
    /60,3));
    17 end;
    18 /
    total minutes.....061
    PL/SQL procedure successfully completed.
    SQL>

    Shrinika wrote:
    Thanks for the clarification.. Now i understand...
    One final question on this thread before i close this thread....
    My database is set to CURSOR_SHARING=FORCE for some reason. It seems somebody applied a "quick and dirty fix" to "database is slow" problem. BAD PRACTICE
    My question is, when we use bind variable, does it parse the sql code every time? or does it reuse the execution plan?
    In my database, it reuse the execution plan... Just checking... When we set CURSOR_SHARING=FORCE, it should generate the execution plan
    for every unqiue sql code... Is that correct? Am i confusing?If by "parse" you mean a "hard parse" (which generates execution plan), then the answer is NO. As you observed, it reuses execution plan.
    For e.g. with CURSOR_SHARING=FORCE setting, following SQLs
    select employee_no, first_name, last_name from employees where dept_no = 10 ;and
    select employee_no, first_name, last_name from employees where dept_no = 20 ;would tend to reuse the same execution plan since both of these will be rewritten by oracle (before execution) as
    select employee_no, first_name, last_name from employees where dept_no = :SYS01 ;Hope this helps.
    Edited by: user503699 on Aug 14, 2010 3:55 AM

  • Why same query takes different execution time in sql 2008

    Hi!
    With below query in SQL Server 2008 R2 when I change Book_ID  to another value like '99000349'  it takes very long time to execute while both result sets have same number of records!?
    select Card_Serial,Asset_ID, Field_Name,Field_Value,Asset_Number,Field_ID,Book_ID from dbo.vw_InspectionReport where Book_ID='99000347'
    I've test it more and more,A time I ran quickest one, or longest one first, restart Windows, but for some specific Book_ID values (although with same number of result set rows) it take multiple time slower than rest of Book_IDs.
    Also showing state of the result set is different for these diffrent Book_IDs:
    for fast ones it looks like below picture:
    for slow ones it looks like below picture:
    if you note, order of returned records are different!?
    I'm waiting for your kindly reply!...

    Do you see any changes if you add a hint to the query?
    select Card_Serial,Asset_ID, Field_Name,Field_Value,Asset_Number,Field_ID,Book_ID from dbo.vw_InspectionReport where Book_ID='99000347OPTION(RECOMPILE)
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • BPS Variable Exit issue - input variable is not hardcoded

    Hi SDNer
    I have a problem in derivation of 3 variables from one variable. The scenario is like this..
    Curr Year - Hard coded in one Pl Area and all other Area get the same value by using a FM
    Planning for year : User Input variable in Layout
    We are planning for Projection ( Ver - p) Budget ( Ver - B) and 3 Forecast (Ver - F)
    Now based on the planning for year and current year variable,system should calculate these three versions.Curr Ver  Next Ver Prev Ver which are in layout at present and entered by user manually
    Example:
    For  Curr Year 2008 and Plan Year 2008
    Curr Ver - P Next Ver - B and Prev Ver - A
    For  Curr Year 2008 and Plan Year 2009
    Curr Ver - B Next Ver - F and Prev Ver - P
    Thanks
    Saurabh

    Hi Kirill
    Still no luck...here is my code
    I am populating Variable ZVAR which is based on 0VERSION. With help of plan year ZFISCYEAR and Current year ZPLYEAR
    I assigned this FM to ZVAR variable in plan area.
    Also i am using this variable along with these 2 time variable in the planning folder......
    I am getting error ZVER can't be computed ????
    FUNCTION VERSION_AUTOMATION_TEST_KAMAL.
    ""Local Interface:
    *"  IMPORTING
    *"     VALUE(I_AREA) LIKE  UPC_AREA-AREA OPTIONAL
    *"     VALUE(I_VARIABLE) LIKE  UPC_VAR-VAR OPTIONAL
    *"  EXPORTING
    *"     REFERENCE(ETO_CHARSEL) TYPE  UPC_YTO_CHARSEL
    Data: lp_subrc type sysubrc.
    Data: lc_subrc type sysubrc.
    Data: lpt_varsel type table of upc_ys_api_varsel.
    Data: lps_varsel type upc_ys_api_varsel.
    *Data: l_plan_year type upc_ys_api_varsel.
    Data: ls_chasel type upc_ys_charsel.
    Data: l_VERSION TYPE C.
    Data: l_plan_year type i.
    Data: l_curr_year type i.
    data: lcto_varsel   TYPE upc_yto_charsel.
    DATA: lcs_varsel TYPE upc_ys_charsel.
    Data: DIFF TYPE i.
    Data: l_area type upc_y_area.
    Data: l_variable type upc_y_variable.
    if i_variable = 'ZFISCYR'.
    *Read Planning For Year Variable.
    call function 'API_SEMBPS_VARIABLE_GETDETAIL'
          Exporting
           i_area = i_area
           i_variable = i_variable
          Importing
           e_subrc = lp_subrc
           tables
           etk_varsel = lpt_varsel.
        if lp_subrc = 0.
          clear lps_varsel.
          read table lpt_varsel into lps_varsel index 1.
          l_plan_year = lps_varsel-low.
        endif.
    Read Current Year Variable.
    *data: l_buffer_call TYPE boole-boole           VALUE 'X'.
        Fix value of current year from below FM
      CALL FUNCTION 'Z_VAR_GET_DETAIL'
            EXPORTING
              i_area     = 'ZPLBSCF1'
              i_variable = 'ZPLYEAR'
            IMPORTING
              e_subrc    = lc_subrc
              eto_varsel = lcto_varsel.
          if lc_subrc = 0.
            clear lcs_varsel.
            read table lcto_varsel into lcs_varsel index 1.
            l_curr_year = lcs_varsel-low.
          endif.
    DIFF = l_plan_year - l_Curr_year.
            IF l_plan_year = l_Curr_year.
                 l_VERSION = 'P'.
                 ELSEIF ( DIFF = 1 ).
                      l_VERSION = 'B'.
                      ELSEIF ( DIFF = 2 ).
                           l_version = 'F'.
                           ELSE.
                                l_VERSION = 'F'.
         ENDIF.
    ls_chasel-chanm = '0VERSION'.
    ls_chasel-opt = 'EQ'.
    ls_chasel-low = l_VERSION.
    insert ls_chasel into table eto_charsel.
    Endif.
    ENDFUNCTION.
    Thanks alot
    Saurabh

  • BPS Variable exits Ranges showing only Low Value

    Hi,
    I am attempting to show a comparison column in my planning layout which represents YTD values.
    The data in my cube is as follows.
    Cal Qtr      Fisc Period      Amount
    2006.1       2006.003           10
    2006.1       2006.001           20
    Now in my variable selection for the layout, i define user exits for cal quarter and fisc period. I define the restriction for cal quarter as  between 2006.1 and 2006.1
    and the restriction for fiscal period as between 2006.001 and 2006.003. However the resulting output is only the data from 2006.001 (the 'low' value = 20). Does anyone know why this is so ? Is this a bug or an expected functionality?
    Thanks for your help.
    Shailesh
    Message was edited by: Shailesh Unny

    Hi,
    In BPS, you can only select a single value.
    If you enter multiple values in your variable, example like you did with 2006.001 to 2006.003, only the lowest value will be used for selection.
    The result is thus the same as if you would have entered 2006.001 to 2006.001.
    This can be bypassed in 2 ways (out of which none deserves the beauty price):
    1) reload the data in your cube and post the result on a single date. You can then restrict your comparison column to this single date.
    2) make the comparison column dynamic on your time variable.
    You will then see 3 columns for each month, you can sum the 3 columns to display the total.
    Please assign points if this was helpful or solved your problem.
    Best Regards,
    Filip

  • Cut down execution time

    So I need to take the execution time of the attached VI down Greatly.  it sits at about 10-15 seconds and i need it to be more like 500ms.  the issue seems to be with extracting the registers from the modbus return and then formatting them to look correct on the VI.  I Have some ideas on cutting this down but they have proved nominal at best.  I could really use some suggestions on this.  it me last major piece on this project.
    thanks,
    Mark R. 
    Attachments:
    Yaskawa data collection.vi ‏83 KB

    You haven't supplied all the SubVIs... But I have some suggestions:
    I notice that the "MB Ethernet Master Query.vi" SubVI is re-used several times for each of your Drives.  If the VI isn't re-entrant then each call will block between drives.
    It can take time to open a connection. It looks like this VI is part of a larger application - you are better off keeping the connection open up-front and only performing the reads when needed.
    The register conversion logic won't be slowing you down; this will execute very quickly. It is more lilkely that the modbus reads are where time is being spent. But again, without the rest of the SubVIs it is hard to give any further guidance.
    It is hard to tell without the SubVI but it looks like you are using a time-out of 10000 seconds for each modbus read. Are you sure one of your requests isn't timing out and adding 10s to your execution time?

  • SAP BW SEM-BPS Variables

    Hi All,
    We are upgrading SAP BW SEM-BPS system from 2.0B to 6.O, in this process i need to collect some information as like below from tables,
    like BPS Variables----- UPC_VAR ,
    planning sequence----- UPC_PROFILE_BU
    planning folder(Web)---- BPS_WB
    planning folder(GUI)---UPSPM
    BPS variable exit--UPC_VAR_EXIT
    respectively, but these tables like UPC_VAR,UPC_PROFILE_BU etc are  NOT there in my system ( SAP BW SEM-BPS 2.0B), So can anyone please suggest me alternative table name OR tell me where can I get aobve information like (BPS Variables, Planning Sequence etcc. ).
    Thank you,
    CCC

    Hi,
    I need to collect same information.
    Will you share it.
    Thanks,
    Ajay

  • More response time

    when program execute at time my program takes more response time so what is reason.

    hi krupa,
    pls check with transaction SE30[Run time analysis] and identify the area where it is taking time.
    pls Re-check u r code with below points.
    1) should not write any select statement in side the loop and endloop.
    2) Use Select into corresponding fields insted of select *
    3) refresh your internal tables after data is processed.
    4) use move corresponding insted of move single
    5)use type insted of like while declaring the parameters.
    6) it would be better if u use workarea
    this is from ABAP side.
    from basis side,
    pls check whether the server is working fine or not??
    if u want more help, pls post u r code.

  • Optimize long execution time due to 'db file sequential read'

    Hi to all,
    I have got a query that takes long execution time. Most of the time is due to 'db file sequential read'. The query is:
    SELECT * FROM Table_Name
    WHERE col1 = :some_value
    AND col2 BETWEEN :some_range_about_2_Million
    | Id | Operation | Name | Rows | Bytes | Cost |
    | 0 | SELECT STATEMENT | | 21 | 504 | 26125 |
    | 1 | TABLE ACCESS BY INDEX ROWID| Table_Name | 21 | 504 | 26125 |
    | 2 | INDEX RANGE SCAN | Index Name | 1705K| | 4100 |
    The table is not partitioned having around 0.2 billion records. Record set for column 'col1' is around 1700K.
    Another index is available for the col2 and col3 is not getting used.
    Any suggestions to optimize it..
    Regards.

    Perhaps a combined index (col2, col1) would work...or try "parallel" hint.
    :p

  • Execution of workbook takes more time

    Hi All,
    I have created one workbook which has one query in it and  and dfata is of this one query is displayed in four sheets , and when executing it is taking more time .
    Kinly let me know how to reduce the execution time of workbook.
    Regards
    Albaik

    Hello,
    Please check if this collection of notes reduces the time:
    1392745 : Workbook caching.
    1480848 : BExAnalyzer: performance improvement in workbook.
    1160093 : Prog error/performance problems when using large.
    1150242 : Improving performance/memory in the BEx Analyzer.
    1179647 : Performance: Network load in BEx Analyzer.
    Make sure the entry ANA_USE_OPTIMIZE_STG = X is made in tcode,
    RS_FRONTEND_INIT. Also make sure the "Use Optimized Storage" option is
    used for the workbook as given in note,
    1260213    Performance problems during workbook opening in Excel 2007
    Regards,
    Michael

  • Query using progressive relaxation take more time for execution

    HI Gurus,
    I am creating a query using context index and progressive relaxation
    I had started using progressive relaxation after getting inputs from forum {thread:id=2333942} . Using progressive relaxation takes more than 7 seconds for every query. Is there any way we can improve the performance of the query?
    create table test_sh4 (text1 clob,text2 clob,text3 clob);
    begin
       ctx_ddl.create_preference ('nd_mcd', 'multi_column_datastore');
       ctx_ddl.set_attribute
          ('nd_mcd',
           'columns',
           'replace (text1, '' '', '''') nd1,
            text1 text1,
            replace (text2, '' '', '''') nd2,
            text2 text2');
       ctx_ddl.create_preference ('test_lex1', 'basic_lexer');
       ctx_ddl.set_attribute ('test_lex1', 'whitespace', '/\|-_+');
       ctx_ddl.create_section_group ('test_sg', 'basic_section_group');
       ctx_ddl.add_field_section ('test_sg', 'text1', 'text1', true);
       ctx_ddl.add_field_section ('test_sg', 'nd1', 'nd1', true);
       ctx_ddl.add_field_section ('test_sg', 'text2', 'text2', true);
       ctx_ddl.add_field_section ('test_sg', 'nd2', 'nd2', true);
    end;
    create index IX_test_sh4 on test_sh4 (text3)   indextype is ctxsys.context   parameters    ('datastore     nd_mcd   lexer test_lex1 section group     test_sg') ;
    alter index IX_test_sh4 REBUILD PARAMETERS ('REPLACE SYNC (ON COMMIT)') ;-- sync index on every commit.
    SELECT SCORE(1) score,t.* FROM test_sh4 t WHERE CONTAINS (text3,  '
    <query>
    <textquery>
    <progression>
    <seq>{GIFT GRILL STAPLES CARD} within text1</seq>
    <seq>{GIFTGRILLSTAPLESCARD} within nd1</seq>
    <seq>{GIFT GRILL STAPLES CARD} within text2</seq>
    <seq>{GIFTGRILLSTAPLESCARD} within nd2</seq>
    <seq>((%GIFT% and %GRILL% and %STAPLES% and %CARD%)) within text1</seq>
    <seq>((%GIFT% and %GRILL% and %STAPLES% and %CARD%)) within text2</seq>
    <seq>((%GIFT% and %GRILL% and %STAPLES%) or (%GRILL% and %STAPLES% and %CARD%) or (%GIFT% and %STAPLES% and %CARD%) or (%GIFT% and %GRILL% and %CARD%)) within text1</seq>
    <seq>((%GIFT% and %GRILL% and %STAPLES%) or (%GRILL% and %STAPLES% and %CARD%) or (%GIFT% and %STAPLES% and %CARD%) or (%GIFT% and %GRILL% and %CARD%)) within text2</seq>
    <seq>((%STAPLES% and %CARD%) or (%GIFT% and %GRILL%) or (%GRILL% and %CARD%) or (%GIFT% and %CARD%) or (%GIFT% and %STAPLES%) or (%GRILL% and %STAPLES%)) within text1</seq>
    <seq>((%STAPLES% and %CARD%) or (%GIFT% and %GRILL%) or (%GRILL% and %CARD%) or (%GIFT% and %CARD%) or (%GIFT% and %STAPLES%) or (%GRILL% and %STAPLES%)) within text2</seq>
    <seq>((%GIFT% , %GRILL% , %STAPLES% , %CARD%)) within text1</seq>
    <seq>((%GIFT% , %GRILL% , %STAPLES% , %CARD%)) within text2</seq>
    <seq>((!GIFT and !GRILL and !STAPLES and !CARD)) within text1</seq>
    <seq>((!GIFT and !GRILL and !STAPLES and !CARD)) within text2</seq>
    <seq>((!GIFT and !GRILL and !STAPLES) or (!GRILL and !STAPLES and !CARD) or (!GIFT and !STAPLES and !CARD) or (!GIFT and !GRILL and !CARD)) within text1</seq>
    <seq>((!GIFT and !GRILL and !STAPLES) or (!GRILL and !STAPLES and !CARD) or (!GIFT and !STAPLES and !CARD) or (!GIFT and !GRILL and !CARD)) within text2</seq>
    <seq>((!STAPLES and !CARD) or (!GIFT and !GRILL) or (!GRILL and !CARD) or (!GIFT and !CARD) or (!GIFT and !STAPLES) or (!GRILL and !STAPLES)) within text1</seq>
    <seq>((!STAPLES and !CARD) or (!GIFT and !GRILL) or (!GRILL and !CARD) or (!GIFT and !CARD) or (!GIFT and !STAPLES) or (!GRILL and !STAPLES)) within text2</seq>
    <seq>((!GIFT , !GRILL , !STAPLES , !CARD)) within text1</seq>
    <seq>((!GIFT , !GRILL , !STAPLES , !CARD)) within text2</seq>
    <seq>((?GIFT and ?GRILL and ?STAPLES and ?CARD)) within text1</seq>
    <seq>((?GIFT and ?GRILL and ?STAPLES and ?CARD)) within text2</seq>
    <seq>((?GIFT and ?GRILL and ?STAPLES) or (?GRILL and ?STAPLES and ?CARD) or (?GIFT and ?STAPLES and ?CARD) or (?GIFT and ?GRILL and ?CARD)) within text1</seq>
    <seq>((?GIFT and ?GRILL and ?STAPLES) or (?GRILL and ?STAPLES and ?CARD) or (?GIFT and ?STAPLES and ?CARD) or (?GIFT and ?GRILL and ?CARD)) within text2</seq>
    <seq>((?STAPLES and ?CARD) or (?GIFT and ?GRILL) or (?GRILL and ?CARD) or (?GIFT and ?CARD) or (?GIFT and ?STAPLES) or (?GRILL and ?STAPLES)) within text1</seq>
    <seq>((?STAPLES and ?CARD) or (?GIFT and ?GRILL) or (?GRILL and ?CARD) or (?GIFT and ?CARD) or (?GIFT and ?STAPLES) or (?GRILL and ?STAPLES)) within text2</seq>
    <seq>((?GIFT , ?GRILL , ?STAPLES , ?CARD)) within text1</seq>
    <seq>((?GIFT , ?GRILL , ?STAPLES , ?CARD)) within text2</seq>
    </progression>
    </textquery>
    <score datatype="FLOAT" algorithm="default"/>
    </query>',1) >0 ORDER BY score(1) DESC

    Progressive relaxation works best when you're only selecting a limited number of rows. If you fetch ALL the rows which satisfy the query, then all the steps in the relaxation will have to run regardless.
    If you fetch - say - the first 10 results, then if the first step of the relaxation provides 10 results then there is no need to execute the next step (in fact, due to internal buffering, that won't be exactly true but it's conceptually correct).
    The simplest way to do this is reword the query as
    SELECT * FROM (
    ( SELECT SCORE(1) score,t.* FROM test_sh4 t WHERE CONTAINS (text3, '
    <query>
    <textquery>
    </textquery>
    <score datatype="FLOAT" algorithm="default"/>
    </query>',1) >0 ORDER BY score(1) DESC
    WHERE ROWNUM <= 10
    You've discovered that leading wild cards don't work too well unless you use SUBSTRING_INDEX. I would encourage you to avoid them altogether if possible, or push them down much lower in the progressive relaxation. Usually, GIFT% is a useful expression (matches GIFTS, GIFTED, etc), %GIFT% is generally no more effective.
    There are a lot of steps in your progressive relaxation. It you wanted to reduce the number of steps, you could change:
    <seq>((%GIFT% and %GRILL% and %STAPLES% and %CARD%)) within text1</seq>
    <seq>((%GIFT% and %GRILL% and %STAPLES% and %CARD%)) within text2</seq>
    to
    <seq>((%GIFT% and %GRILL% and %STAPLES% and %CARD%)*2) within text1 ACCUM ((%GIFT% and %GRILL% and %STAPLES% and %CARD%)) within text2</seq>
    I don't know if this would have any performance benefits - but it's worth trying it to see.

  • Query takes more time from client

    Hi,
    I have a select query (which refers to views and calls a function), which fetches results in 2 secs when executed from database. But takes more than 10 mins from the client.
    The tkprof for the call from the client is given below. Could you please suggest, what is going wrong and how this can be addressed?
    The index IDX_table1_1 is on col3.
    Trace file: trace_file.trc
    Sort options: exeela 
    count    = number of times OCI procedure was executed
    cpu      = cpu time in seconds executing
    elapsed  = elapsed time in seconds executing
    disk     = number of physical reads of buffers from disk
    query    = number of buffers gotten for consistent read
    current  = number of buffers gotten in current mode (usually for update)
    rows     = number of rows processed by the fetch or execute call
    SELECT ROUND(SUM(NVL((col1-col2),(SYSDATE - col2)
    FROM
    table1 WHERE col3 = :B1 GROUP BY col3
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        0      0.00       0.00          0          0          0           0
    Execute   7402      0.27       7.40          0          0          0           0
    Fetch     7402      1.13      59.37       1663      22535          0        7335
    total    14804      1.40      66.77       1663      22535          0        7335
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 32  (ORADBA)   (recursive depth: 1)
    Rows     Execution Plan
          0  SELECT STATEMENT   MODE: ALL_ROWS
          0   SORT (GROUP BY NOSORT)
          0    TABLE ACCESS   MODE: ANALYZED (BY INDEX ROWID) OF 'table1'
                   (TABLE)
          0     INDEX   MODE: ANALYZED (RANGE SCAN) OF 'IDX_table1_1'
                    (INDEX)
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      db file sequential read                      1663        1.37         57.71
    OVERALL TOTALS FOR ALL NON-RECURSIVE STATEMENTS
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        0      0.00       0.00          0          0          0           0
    Execute      0      0.00       0.00          0          0          0           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        0      0.00       0.00          0          0          0           0
    Misses in library cache during parse: 0
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      db file sequential read                     16039        3.09        385.04
      db file scattered read                         34        0.21          1.42
      latch: cache buffers chains                    26        0.34          2.14
      SQL*Net break/reset to client                   2        0.05          0.05
      SQL*Net message to client                       2        0.00          0.00
      SQL*Net message from client                     2       79.99         79.99
      SQL*Net message to dblink                       1        0.00          0.00
      SQL*Net message from dblink                     1        0.00          0.00
    OVERALL TOTALS FOR ALL RECURSIVE STATEMENTS
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        0      0.00       0.00          0          0          0           0
    Execute   7402      0.27       7.40          0          0          0           0
    Fetch     7402      1.13      59.37       1663      22535          0        7335
    total    14804      1.40      66.77       1663      22535          0        7335
    Misses in library cache during parse: 0
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      db file sequential read                      1663        1.37         57.71
        1  user  SQL statements in session.
        0  internal SQL statements in session.
        1  SQL statements in session.
        1  statement EXPLAINed in this session.
    Trace file: trace_file.trc
    Trace file compatibility: 10.01.00
    Sort options: exeela 
           1  session in tracefile.
           1  user  SQL statements in trace file.
           0  internal SQL statements in trace file.
           1  SQL statements in trace file.
           1  unique SQL statements in trace file.
           1  SQL statements EXPLAINed using schema:
               ORADBA.prof$plan_table
                 Default table was used.
                 Table was created.
                 Table was dropped.
       84792  lines in trace file.
        4152  elapsed seconds in trace file.Edited by: agathya on Feb 26, 2010 8:39 PM

    I have a select query (which refers to views and calls a function), which fetches results in 2 secs when >executed from database. But takes more than 10 mins from the client.You are providing proof for the latter part of your statement above.
    But not for the former part (fetches in 2 secs when exec'd from db).
    It would have been nice if you also provide the sql-trace information for that.
    Without it we cannot help you much. Other than making the observation that you obviously have a query that is I/O bound, and that I/O on your system is rather slow: on average an I/O takes 0.04 seconds (66.77 divided by 1663).

  • Threaded program takes more time than running serially!

    Hello All
    Ive converted my program into a threaded application so as to improve speed. However i found that after converting the execution time is more than it was when the program was non threaded. Im not having any synchronised methods. Any idea what could be the reason ?
    Thanx in advance.

    First, if you are doing I/O, then maybe that's what's taking the time and not the threads. One question that hasn't been asked about your problem:
    How much is the time difference? If it takes like 10 seconds to run the one and 10 minutes to run the threaded version, then that's a big difference. But if it is like 10 seconds vs 11 seconds, I think you should reconsider if it matters so much.
    One analogy that comes to mind about multiple threads vs. sequential code is this:
    With sequentially run code, all the code segments are lined up in order and they all go thru the door one after the other. As one goes thru they all move up closer, thus they know who's going first.
    With multi-threaded code, all the code segments sorta pile up around the door in a big crowd. Some push go thru one at a time while others let them (priority), while other times 2 go for the door at the same time and there might be a few moments of "oh, after you", "no, after you", "oh no, I insist, after you" before one goes thru. So that could introduce some delay.

Maybe you are looking for

  • Viewto TVd ing photo and video from Iphone and Ipod to TV

    I am trying to connect my Ipod classic to my Panasonic TC-P42X1 to view pictures and video. I have used the Apple component AV , connecting the red, blue and green video connectors to component 1 video input ports on the TV and the white and red audi

  • Select data based on status priority

    ID     PRO_ID     PRO_OBJ_ID     TASK_ID     DEVELOPER_ID     STATUS 121243     4940     37506     5250     6532     REJECTED 122063     4940     37506     5250     6532     CLOSE 138306     4940     37506     5250     6532     ACCEPTED 138307     49

  • Web Service Model transforms dateTime elements to java.util.Calendar

    The issue is that my EJB returns a java.util.Date object, the WS that exposes this EJB states in the wsdl that it returns a dateTime element (see attachment). Web Dynpro web-service model, when given the wsdl generates proxies that receive a java.uti

  • Locking Out OS X Rights

    Hi everyone, thanks for any help on this. Currently we have all of our users that have OSX set as administrator users. According to the policies here they have the ability to update their software as well as update the installed Adobe products and ot

  • SATA HD's biting the dust?

    hello, everyone- I have had an ongoing problem with my primary storage setup- two Maxtor 250GB (pulls from G5's) SATA's into a SIIG 4-port SATA card. I was running them mirrored as my main disk for a while, until they started bugging out. when I star