Index in GLPCA

Hi all,
We need to do extracts from GLPCA by an external connector (Qlickview) on a regular basis (daily or weekly) but we dont have any good indexes to use. Currently we are searching using fields RLDNR, RRCTY, RVERS, RYEAR, RBUKRS and perhaps POPER.
Would it be a good idea to put an index on CPUDT and CPUTM (creation date and time) to be able to extract data based on that info? How will performance be affected in the applications by adding another index?
We have 113 million rows and are adding approx 5 M per month. Will it take forever to create the new index?
Can I perhaps build the index "behind" SAP, ie directly in the database somehow?
Any other suggestion?
best regards,
Glenn

Would it be a good idea to put an index on CPUDT and CPUTM (creation date and time) to be able to extract data based on that info?
If your needs are based on these fields, then certainly it would make your extarction faster.
How will performance be affected in the applications by adding another index?
Any SAP program that writes to this table will be impacted by this index.... this is b/c the new index needs to be updated (as well as the actual table).  The impact is not enormous as long as you do not have a large number of indexes currently. 
The "rule of thumb" for indexes... if the business truly needs the info processed in atimely fashion, you MUST create the index.  If timeliness is not of great importance, then live without it.
We have 113 million rows and are adding approx 5 M per month. Will it take forever to create the new index?
It is recommended to create an index of this size during a "down" time.  The creation will take a while... and an application that references the table will be halted until the new index is built.  That is why a down time is best.
Can I perhaps build the index "behind" SAP, ie directly in the database somehow?
And yes, your DBAs can build index at the DB level.  Your extractor will "find" this new index and use it.  The negative is that your developers will not know that index actually exists b/c it will not be visible in SE11 for the table (unless you enter it later).
Hope this helps.

Similar Messages

  • Partial fields of Secondary index being used by the DB Optimizer

    Hello,
    I have written the following Query to select an std. SAP Index from GLPCA~1. However, when i run the SQL trace although the index is selected by the DB optimizer the results say that only 3 matching columns were used.
    bold Index GLPCA~1. bold
    KOKRS
    RYEAR
    RPRCTR
    RVERS
    RACCT
        SELECT rldnr
               rrcty
               rvers
               ryear
               rtcur
               rpmax
               rbukrs
               rprctr
               rfarea
               kokrs
               racct
               hslvt
               hsl01
               hsl02
               hsl03
               hsl04
               hsl05
               hsl06
               hsl07
               hsl08
               hsl09
               hsl10
               hsl11
               hsl12
               kslvt
               ksl01
               ksl02
               ksl03
               ksl04
               ksl05
               ksl06
               ksl07
               ksl08
               ksl09
               ksl10
               ksl11
               ksl12
               FROM glpct
               INTO TABLE i_glpct
               WHERE kokrs = 'BFS'
                  AND ryear = p_gjahr
                  AND rprctr IN r_prctr
                  AND rvers = '000'
                  AND racct IN r_acct.
    Now i am not sure which of the above 3 fields of the where condition are being selected but probably KOKRS and RVERS are not being used by the optimizer.
    Any pointers on how to make the optimizer utilize all 5 fields would be greatly appreciated.
    Thanks,
    Minhaj.

    Hello,
    I have written the following Query to select an std. SAP Index from GLPCA~1. However, when i run the SQL trace although the index is selected by the DB optimizer the results say that only 3 matching columns were used.
    bold Index GLPCA~1. bold
    KOKRS
    RYEAR
    RPRCTR
    RVERS
    RACCT
        SELECT rldnr
               rrcty
               rvers
               ryear
               rtcur
               rpmax
               rbukrs
               rprctr
               rfarea
               kokrs
               racct
               hslvt
               hsl01
               hsl02
               hsl03
               hsl04
               hsl05
               hsl06
               hsl07
               hsl08
               hsl09
               hsl10
               hsl11
               hsl12
               kslvt
               ksl01
               ksl02
               ksl03
               ksl04
               ksl05
               ksl06
               ksl07
               ksl08
               ksl09
               ksl10
               ksl11
               ksl12
               FROM glpct
               INTO TABLE i_glpct
               WHERE kokrs = 'BFS'
                  AND ryear = p_gjahr
                  AND rprctr IN r_prctr
                  AND rvers = '000'
                  AND racct IN r_acct.
    Now i am not sure which of the above 3 fields of the where condition are being selected but probably KOKRS and RVERS are not being used by the optimizer.
    Any pointers on how to make the optimizer utilize all 5 fields would be greatly appreciated.
    Thanks,
    Minhaj.

  • Performance problems with 0EC_PCA_3 datasource

    Hi experts,
    We have recently upgraded the Business Content in our BW system, as well as the plug-in on R/3 side. Now we have BC3.3 and PI2004.1. Given the opportunity, we decided to apply the new 0EC_PCA_3 and 0EC_PCA_4 datasources that provide more detailed data from table GLPCA.
    The new datasources have been activated and transported to the QA system, where we experience serious performance problems while extracting data from R/3. All other data extractions work as before so there should not be any problem with the hardware.
    Do you use 0EC_PCA_3? Have you experienced any problem with the speed of data extraction/transfer? We already have applied the changes suggested in note 597909 (Performance of FI-SL line item extractors: Creating indexes) and created secondary indexes on GLPCA table but it did not help.
    thanks and regards,
    Csaba

    Seems the problem was caused by a custom development - quantity conversion in user exit. However, we tried loading earlier after removal of the exit, it did not help then (loading took even longer...). Now it did.

  • RCOPCA02  GLPCA

    Hello
    I have a problem using report RCOPCA02,
    when i double click a line to have an output list it takes a long time.
    The problem could be the raise of table GLPCA and through the note 212964 the only solution , i suppose, is
    to create another index for this report.
    The query is the following:
    SELECT                                                                               
    "RCLNT" , "RLDNR" , "KOKRS" , "RYEAR" , "RBUKRS" , "RRCTY" , "RVERS" , "POPER" , "RTCUR" ,       
      "RUNIT" , "DRCRK" , "DOCCT" , "DOCNR" , "DOCLN" , "RPRCTR" , "RHOART" , "RFAREA" , "RACCT" ,     
      "HRKFT" , "RASSC" , "EPRCTR" , "ACTIV" , "AFABE" , "SBUKRS" , "SPRCTR" , "SHOART" , "SFAREA" ,   
      "TSL" , "HSL" , "KSL" , "MSL" , "CPUDT" , "CPUTM" , "USNAM" , "SGTXT" , "AUTOM" , "DOCTY" ,      
      "BLDAT" , "BUDAT" , "WSDAT" , "REFDOCNR" , "REFRYEAR" , "REFDOCLN" , "REFDOCCT" , "REFACTIV" ,   
      "AWTYP" , "AWORG" , "AWSYS" , "WERKS" , "GSBER" , "KOSTL" , "LSTAR" , "AUFNR" , "AUFPL" ,        
      "ANLN1" , "ANLN2" , "MATNR" , "BWKEY" , "BWTAR" , "ANBWA" , "KUNNR" , "LIFNR" , "RMVCT" ,        
      "EBELN" , "EBELP" , "KSTRG" , "ERKRS" , "PS_PSP_PNR" , "KDAUF" , "KDPOS" , "FKART" , "VKORG" ,   
      "VTWEG" , "AUBEL" , "AUPOS" , "SPART" , "VBELN" , "POSNR" , "VKGRP" , "VKBUR" , "LOGSYS" ,       
      "VERSA" , "STFLG" , "STOKZ" , "STAGR" , "GRTYP" , "REP_MATNR" , "CO_PRZNR" , "IMKEY" , "DABRZ" , 
      "RSCOPE" , "BWART" , "BLART"                                                                     
    FROM                                                                               
    "GLPCA"                                                                               
    WHERE                                                                               
    "RLDNR" = :A0 AND "RRCTY" IN ( :A1 , :A2 ) AND "RVERS" = :A3 AND "KOKRS" = :A4 AND "RYEAR" = :A5 
      AND "RACCT" = :A6 AND "POPER" BETWEEN :A7 AND :A8 AND ( ( "ACTIV" BETWEEN :A9 AND :A10 OR "ACTIV"
      BETWEEN :A11 AND :A12 OR "ACTIV" BETWEEN :A13 AND :A14 OR "ACTIV" BETWEEN :A15 AND :A16 ) OR     
      "ACTIV" IN ( :A17 , :A18 ) ) AND "RCLNT" = :A19#      
    and it uses this index:
    RYEAR  
    POPER  
    RBUKRS 
    RACCT  
    it has an estimate cost too high. i'd like to reduce it. which index do you suggest for this activity? my doubt is about the field RCLNT that is at the end of the query...it sounds strange....anyway any help is appeciated...
    thanks a lot
    Nick

    Hi,
    what fiels does the YBA index consist of? (RYEAR POPER RBUKRS RACCT )?
    WHERE  "RLDNR" = :A0
    AND "RRCTY" IN ( :A1 , :A2 )
    AND "RVERS" = :A3
    AND "KOKRS" = :A4
    AND "RYEAR" = :A5
    AND "RACCT" = :A6
    AND "POPER" BETWEEN :A7 AND :A8
    AND ( ( "ACTIV" BETWEEN :A9 AND :A10
    OR "ACTIV" BETWEEN :A11 AND :A12
    OR "ACTIV" BETWEEN :A13 AND :A14
    OR "ACTIV" BETWEEN :A15 AND :A16 )
    OR "ACTIV" IN ( :A17 , :A18 ) )
    AND "RCLNT" = :A19
    In SE16 you can check which of the above variables limit the resultset most.
    Normally these coloumns should be indexed.
    Again: How big is the result set of your query? (What is the time per record?)
    Kind regards,
    Hermann

  • GLPCA Data extraction in BW...

    I need to bring in GLPCA data into BW.I am going to activate the datasource 0EC_PCA_3 and created an ODS based on it.I need to combine the GLPCA data with Billing data to meet my requirements.Will there be any performance issues in brining in GLPCA data into BW.Please do let me know.

    Hi Akhil,
    Not sure what is the data loads that you are looking at. If the data volume is too high you can think of initialising the Datasources in buckets based on periods.
    I have used the same datasource 0EC_PCA_3 for initial extraction of around 17 million records faced no problems. I had initialised the datasource for one fiscal year at a time, i.e. 001.2004 to 012.2004, 001.2005 to 012.2005 and so on.
    Also take a look at the help link below,
    (an extract of the same below)
    http://help.sap.com/saphelp_nw2004s/helpdata/en/5d/ac7d8082a27b438b026495593821b1/frameset.htm
    To optimize the performance of data procurement when DataSource 0EC_PCA_3 accesses line item table GLPCA in the OLTP, you should set up an additional secondary index. This should contain the following fields:
    · RCLNT
    · CPUDT
    · CPUTM
    Hope it helps.
    Cheers
    Anurag
    .....don't forget to assign points if it helps....

  • GLPCA 185 GB

    we have the table GLPCA with 185GB (2.5 years)
    the technical settings are that
    Data class         APPL1
    Size category      4    
    we want to move 
    Size category      4    
    to
    Size category      9
    what is the impact ??
    we won performace??

    I don't think any thing will happen on SQL Server, because you don't have tablespaces in SQL Server. It's used in Oracle and UDB only. But even on those DB's it only take effect during the creation of the table or index.

  • GLPCA  Table taking too muchtime

    Hi,
       In My GLPCA table around 70 lacks entries are there.When iam cancelling any document its taking too much time.is it possible to do only glpca table archiving or i have to check any abap code.guide me for the same.
    Thanku

    Hi,
    Just try this option as it has worked past:
    A new index with the fields RBUKRS and AUFNR will improve the
    performance significantly!!!    Note 565582
    Thank you,
    Tilak

  • Stms and scc5 error on table glpca

    We will PRD data STMS to DEV new CLIENT error, the log as follows :
    日志文件:                F:\usr\sap\trans\log\TPDIT00026.TOD  -
    主要的输入                                                                               
    传送需求__:TPDKT00026                                                                               
    系统______________: TOD                                                                               
    tp 路径           : tp                                                                               
    版本和释放: 340.16.09 640                                                                               
    Update and insert sequence failed due to conflicting unique indexes on table GLPCA (please read OSS note 626915 for details)       
            SQL错21存取GLPCA:[21] Warning: Fatal error 823 occurred at Aug 15 2                                                                
            sap_dext called with msgnr 1:                                                                               
    db call info -
    function:   db_ntab                                                                               
    fcode:      NT_RDFDESCR                                                                               
    tabname:    GLPCC                                                                               
    len:        11                                                                               
    key:        GLPCC.MANDT                                                                               
    retcode:    1                                                                               
    主要的输入                                                                               
    结束日期和时间: 20070815160428                                                                               
    &#32467;&#26463;&#26102;&#24102;&#26377;&#36820;&#22238;&#30721;: ===> 12 <===                                                                               
    We want to deleted the CLIENT in the DEV when the test run without errors. When implementation acquired deleted when the error occurred, log as follows :
    Client to be Deleted              300
    &#22797;&#21046;&#31867;&#22411;                          Delete Complete Client
    &#29366;&#24577;                              Cancelled
    &#29992;&#25143;                              ZYGUO
    Start on                          2007-08-17 / 10:33:14
    Last Entry on                     2007-08-17 / 10:58:24
    Last Action:                      Copy/Delete Tables
    -  Table Being Edited:            GLPCA
    Statistics for this Run
    - No. of Tables                  7,310  &#30340;       29,939
    - Deleted Lines                      0
    Check System Log (SM21)
    I have carefully analyzed log and view a presentation and the related NOTE still no way to solve the problem.
    Why GLPCA table with the above two errors.How should I deal with these two issues?
    CAN ANYONE HELP ME&#65281;

    Hi,
    Have a look at the  SAP Note 1276895 - Add. info. about Upgrading to SAP Solution Manager 7.0 EHP1 and
    SAP Note 1169247 - Enhancements to Solution Manager 7.0 EHP1 upgrade.
    Thnx,
    Waseem.

  • Missing Index issue.

    Dears,
    I am getting following error in DB02 in Missing index option.
    Missing indexes. Check of 19.07.2008 07:04:31
           Indexes missing in the database
               Primary indexes                  1
                   ZRECEIPTS-0
               Secondary indexes                6
                   BSIS-ZCH
                   BSIS-ZGL
                   EKBE-M01
                   GLPCA-BL
                   MBEW-ZMK
                   ZCND-CD
    Please suggest how to resolve this issue.
    Deepak

    Hi,
    I created Indexes maually but in one index its showing:
    Request: Create Index ZCND-CD (ANKITG/19.07.08/10:19)
    Process: MSLDEV_1
    sql:
    CREATE UNIQUE INDEX "ZCND~CD" ON "ZCND"
    ("MANDT",
    "STATS")
    PCTFREE 10
    INITRANS 002
    TABLESPACE PSAPDS1
    STORAGE (INITIAL 0000000016 K
    NEXT 0000000016 K
    MINEXTENTS 0000000001
    MAXEXTENTS UNLIMITED
    PCTINCREASE 0000
    FREELISTS 001)
    ORA-01452: cannot CREATE UNIQUE INDEX; duplicate keys found
    DDL time(___1): ........43 milliseconds
    The SQL statement was not executed
    Index   could not be created completely in the database
    Index ZCND-CD could not be created
    Request for ZCND could not be executed
    Please suggest.
    Deepak

  • Which to use - Sy-index or sy-tabix ??

    This is what i found out about SY-INDEX and SY-TABIX but which one to use when i want to delete a line of data from an internal table ? I tried both sy-index and sy-tabix and both works fine and returning the expected output for me but which one is better of to use ?
    SY-TABIX :- For Internal Table, Current Line Index
    SY-INDEX :- For Loops, Current Loop Pass
    The below code is where i uses the Delete ..
    LOOP AT dmg.
            CONCATENATE
                   dmg-dmg00
                   dmg-dmg01
                   dmg-dmg02
                   dmg-dmg03
                   dmg-dmg04
                   dmg-dmg07
                   dmg-dmg08
                   dmg-dmg09 INTO tli_down1 SEPARATED BY '*'.
            APPEND tli_down1. CLEAR tli_down1.
            DELETE dmg INDEX sy-index.
            EXIT.
          ENDLOOP.

    Right. Just like what they said upstairs, sy-babix is the best choice.
    One more thing is, if you want to concatenate fields of table dmg and append to tli_down1 on by one. You should not use EXIT after delete dmg.
    In that case ,only one line can be appended into tli_down1 table.
    > The below code is where i uses the Delete ..
    >
    > LOOP AT dmg.
    >         CONCATENATE
    >        dmg-dmg00
    >         dmg-dmg01
    >        dmg-dmg02
    >         dmg-dmg03
    >        dmg-dmg04
    >         dmg-dmg07
    >        dmg-dmg08
    >         dmg-dmg09 INTO tli_down1 SEPARATED BY '*'.
    >   APPEND tli_down1. CLEAR tli_down1.
    >       DELETE dmg INDEX sy-index.
    >   EXIT.
    >     ENDLOOP.

  • Index's on cubes or Aggregates on infoobjects

    Hello,
    Please tell me if it is possible to put index's on cubes; are they automatically added or is this something I put on them?
    I do not understand index's are they like aggregates?
    Need to find info that explains this.
    Thanks for the hlep.
    Newbie

    Indexes are quite different from aggregates.
    An Aggregate is a slice of a cube which helps the data retrival on a faster note when a query is executed on a cube. Basically it is kind of a snapshot of KPI's and Business Indicators (Chars) which will be displayed as the initial query run result.
    Index is a process which is inturn will reduce the query response time. While an object gets activated, the system automatically create primary indexes. Optionaly, you can create additional index called secondary indexes.Before loading data, it is advisable to delete the indexes and insert them back after the loading.
    Indexes act like pointers for quickly geting the Data.When u delete it will delete indexes and when u create it will create the indexes.
    When loading we delete Bcs during loading it has to look for existing Indexes and try to update so it will effect the Data load performence so we delete and create it will take less time when compared to updating the existing ones.
    There is one more issue we have to take care if u r having more than 50 million records this is not a good practice insteah we can delete and create during week end when they r no users.

  • LIKE, LIKEC and Index usage

    I've table that contains about 20 million rows, and I've created index for varchar2(100) column. It works well if I do
    SELECT * FROM MY_TABLE WHERE MY_COL LIKE 'FOO%';
    But if I change query to use LIKEC (to make unicode escaped strings work):
    SELECT * FROM MY_TABLE WHERE MY_COL LIKEC 'FOO%';
    I always get full table scan in explain plan.
    I tried to use NVARCHAR, or index created by TO_NCHAR but I always end up hitting full table scan.
    Should I create index some special way or do something else before I get index working?

    Just a gut feeling : is the database using character semantics or byte semantics?
    My gut feeling, after looking up the documentation, is it should be character semantics.
    BTW: Not posting version info decreases the chance you get an adequate reply.
    Sybrand Bakker
    Senior Oracle DBA

  • Index with "or" clause (BUG still exists?)

    The change log for 2.3.10 mentions "Fixed a bug that caused incorrect query plans to be generated for predicates that used the "or" operator in conjunction with indexes [#15328]."
    But looks like the Bug still exists.
    I am listing the steps to-repro. Let me know if i have missed something (or if the bug needs to be fixed)
    DATA
    dbxml> openContainer test.dbxml
    dbxml> getDocuments
    2 documents found
    dbxml> print
    <node><value>a</value></node>
    <node><value>b</value></node>
    INDEX (just one string equality index on node "value")
    dbxml> listIndexes
    Index: unique-node-metadata-equality-string for node {http://www.sleepycat.com/2002/dbxml}:name
    Index: node-element-equality-string for node {}:value
    2 indexes found.
    QUERY
    setVerbose 2 2
    preload test.dbxml
    query 'let $temp := fn:compare("test", "test") = 0
    let $results := for $i in collection("test.dbxml")
    where ($temp or $i/node[value = ("a")])
    return $i
    return <out>{$temp}{$results}</out>'
    When $temp is true i expected the result set to contain both the records, but that was not the case with the index. It works well when there is no index!
    Result WITH INDEX
    dbxml> print
    <out>true<node><value>a</value></node></out>
    Result WITHOUT INDEX
    dbxml> print
    <out>true<node><value>a</value></node><node><value>b</value></node></out>

    Hi Vijay,
    This is a completely different bug, relating to predicate expressions that do not examine nodes. Please try the following patch, to see if it fixes this bug for you:
    --- dbxml-2.3.10-original/dbxml/src/dbxml/optimizer/QueryPlanGenerator.cpp     2007-04-18 10:05:24.000000000 +0100
    +++ dbxml-2.3.10/dbxml/src/dbxml/optimizer/QueryPlanGenerator.cpp     2007-08-08 11:32:10.000000000 +0100
    @@ -1566,11 +1572,12 @@
         else if(name == Or::name) {
              UnionQP *unionOp = new (&memMgr_) UnionQP(&memMgr_);
    +          result.operation = unionOp;
              for(VectorOfASTNodes::iterator i = args.begin(); i != args.end(); ++i) {
                   PathResult ret = generate(*i, ids);
                   unionOp->addArg(ret.operation);
    +               if(ret.operation == 0) result.operation = 0;
    -          result.operation = unionOp;
         // These operators use the presence of the node arguments, not their valueJohn

  • INDEX vs TABIX

    Hi,
    Can some body explain the CLEAR difference between Sy-index and Sy-tabix. And one or two small examples. I am little bit confused.
    Thanx.

    Hi,
    SY-INDEX
    In a DO or WHILE loop, SY-INDEX contains the number of loop passes including the current pass.
    SY-TABIX
    Current line of an internal table. SY-TABIX is set by the statements below, but only for index tables. The field is either not set or is set to 0 for hashed tables.
    APPEND sets SY-TABIX to the index of the last line of the table, that is, it contains the overall number of entries in the table.
    COLLECT sets SY-TABIX to the index of the existing or inserted line in the table. If the table has the type HASHED TABLE, SY-TABIX is set to 0.
    LOOP AT sets SY-TABIX to the index of the current line at the beginning of each loop lass. At the end of the loop, SY-TABIX is reset to the value that it had before entering the loop. It is set to 0 if the table has the type HASHED TABLE.
    READ TABLE sets SY-TABIX to the index of the table line read. If you use a binary search, and the system does not find a line, SY-TABIX contains the total number of lines, or one more than the total number of lines. SY-INDEX is undefined if a linear search fails to return an entry.
    SEARCH <itab> FOR sets SY-TABIX to the index of the table line in which the search string is found.
    regards,
    madhu

  • What is" LINE-COL2 = SY-INDEX ** 2."

    can u explain what is '' ** "
    FIELD-SYMBOLS <FS> LIKE LINE OF ITAB.
    DO 4 TIMES.
      LINE-COL1 = SY-INDEX.
      LINE-COL2 = SY-INDEX ** 2.  "what this will do
      APPEND LINE TO ITAB.
    ENDDO.

    Hi sunil,
    1 **   means "To the power of"
    2. eg. 5 ** 2  =  25
       (5 To the power of 2 = 25)
    regards,
    amit m.

Maybe you are looking for