Skip a particular Index

A quick one about Oracle Indexes....
Is it possible to disable a particular index (for a period of time) but still keep it online such that all changes are still updated in the index but it is not used during queries? I don't want to rebuild the index when I enable it again.

>
Is it possible to disable a particular index (for a period of time) but still keep it online such that all changes are still updated in the index but it is not used during queries? I don't want to rebuild the index when I enable it again.
>
Ther is a New Feature introduced in 11g exactly for this:
SQL> alter index <name> invisible;This will make the index invisible for the optimizer, but DML will still maintain the index. Main purpose for this is, you can check whether the index is needed before you decide to actually drop it. Should somebody complain, you bring it back instantly with
SQL> alter index <name> visible;Kind regards
Uwe
http://uhesse.wordpress.com

Similar Messages

  • INSERTING A VALUES IN A DDIC TABLE AT A PARTICULAR INDEX VIA WORKAREA

    HI ALL
    Can I INSERT a value at a particular index in a DDIC table via a workarea with similar structure.??
    like if I have a DDIC table with four feilds and creating a internal table and a workarea with similar structure.
    after fetching the values from DDIC table to our internal table and making some changes or wants to insert a values at a particular index. Then Cal I write like:
    INSERT WA INTO zMARA INDEX 2.
    IS IT WRITE?
    OR PLEASE SUGGEST ME THE CORRECT CODE.

    You can insert or rather update the row of table desired by using Primary key combination..
    A Db table will have at least one primary key. So first select the desired record to be updated using
    unique combination of primary key to get the row you want to modify in work area then change the
    value of that field in work are and then use MODIFY db table from workarea.. Remembr you can't change primary key
    If key combination is not found in DB table mentioned in work area  then it will insert the row in ZABC..
    Code..
    consider ZABC having 2 fileds AA and BB, then consider AA as primary key.. and BB as normal field..
    Consider row having value AA = 1 and BB = 2.
    data: wa_ZABC type ZABC.
    data: i_zabc type table of zabc with header line.
    Select single * from ZABC into wa_zabc where AA = '1'.
    wa_zabc-bb = '3'.
    modify ZABC from wa_zabc.
    if you want to change multiple lines in internal table and then update in DB table then use
    Modify ZABC from table i_zabc. after selecting value of zabc in i_zabc and then change
    value by loop .. endloop and then apply the Modify statement..
    Hope this solves your query..
    Regards,
    Uday Desai.

  • Which queries using particular index?

    Hello,
    Is it possible in Oracle 11gR2 to find out which queries are using or used particular INDEX? 
    Thanks a lot for your suggestion.
    Best Regards

    Hello,
    Thanks a lot.
    I have queried what you suggested, and got 5 sql_ids, but I quickly got the EXPLAIN PLAN for all the 5 sql_ids after getting sql_text, but the index I am looking for is not in the NAME column of select * from table (dbms_xplan.display());
    select distinct(sql_id) from v$sql_plan where object_owner = 'HEMANT' and object_name = '&myindex';
    I am little confused now, as v$sql_plan showing 5 sqls based on myindex but no one is actually using index?
    Thank you.
    Best Regards

  • Oracle insists on using particular index in SELECT -- HELP!!!

    Here's the situation:  Back in November, I wrote a report program that contained the following SELECT statement on SAP table FMIFIIT:
    * Get data from the FMIFIIT table.
      SELECT trbtr
             fmbelnr
             fmbuzei
             fonds
             fistl
             farea
             measure
             fipex
             zhldt
             sgtxt
             grant_nbr
        FROM fmifiit
        INTO TABLE it_fmifiit_data
       WHERE zhldt >= p_bpdte                            AND
             zhldt <= p_epdte                            AND
             fistl IN r_fndctr                           AND
             fistl BETWEEN '4011000000' AND '4013999999' AND
             fonds IN r_fund                             AND
             fipex BETWEEN '500000' AND '599999'         AND
             measure <> 'GRANT RELEVANT'                 AND
             measure IN s_rio                            AND
             wrttp NOT IN ('51','60','81')               AND
             stats = ' '.
    I ran into time-out issues with this statement, so a new index ("Z5") was created on the following fields:  ZHLDT, FISTL, FONDS, and FIPEX.  This was the 11th custom index added to the table.  The program was re-run, the statement picked up the new index, and it ran much faster.  Problem solved.
    Fast-forward to this week.  I wrote a new report program that used a SELECT statement virtually identical to the one above.  It looks like this:
    * Get FMIFIIT data.
      SELECT gjahr
             knbelnr
             knbuzei
             measure
             trbtr
             fmbelnr
             fmbuzei
             fonds
             fistl
             farea
             fipex
             zhldt
             sgtxt
          FROM fmifiit
          INTO TABLE it_fmifiit
       WHERE zhldt >= p_bpdte                    AND
             zhldt <= p_epdte                    AND
             fistl IN r_fndctr                   AND
             fonds IN r_fund                     AND
             fipex BETWEEN '500000' AND '599999' AND
             measure <> 'GRANT RELEVANT'         AND
             measure IN s_rio                    AND
             wrttp NOT IN ('51','60','81')       AND
             stats = ' '.
    Again, the program began running into time-out issues on this statement.  I did a trace using ST05, and I found that the system was choose index "3" (FONDS, FIPEX, FIPOS) instead of the obviously-better "Z5" index created a few months ago.
    I tried all kinds of things to figure out why it was choosing "3" to no avail.  Basis even re-ran statistics on the FMIFIIT table, but that didn't work.  Right now, my only option is to add an Oracle hint to the SELECT statement to force it to use index "Z5".  In our DEV system, I've used SE30 to verify that this definitely improves the timing bottleneck that occurs when "3" is used.
    I've only been an ABAP programmer for a few years now, and this one is technically beyond my knowledge.  I don't know what else to try, and I don't know how to determine why the system keeps choosing the index it does.  It's especially frustrating when the SELECT statement is so similar to the one from above, and in that case, it DOES pick up the "Z5" index.
    Does anyone have any information/strategies/suggestions?  At this point, I'm all ears.
    Thanks so much!
    Dave

    Hi Dave,
    based on the query I cannot share your view that there is an obvious choice.
    In fact the best index choice depends on what your data looks like and how are the In-lists filled.
    Maybe the range conditions are very useful, maybe the in-lists are the most selective criteria.
    As a detailed analysis of this is a bit heavy to be done via this forum, why don't you just implement the hint and live happily with it?
    Since you find your index sensible and have proven that it leads to better performance, you obviously know more about your data than Oracle does by the statistics.
    Now you can either try and learn how the Oracle CBO works (there are notes and books available on this topic) or you just use your workaround although you may not exactly understand the reasons for the problem.
    In general - if this would be a support message - I would ask you to ensure that all parameter recommendations are implemented and all CBO patches are installed.
    Then I'd use the sql-statement data collection script (there's a sap note containing this script - just search for 'sql_id') to gather much of the relevant data.
    And then I'd have to look into the data and figure out what's behind the CBOs decision.
    As you wrote that you're rather on the ABAP side of live this effort may not necessarily be worthwhile when you have a proven workaround at hand.
    regards,
    Lars

  • How to specify a particular index for DB2 database when using SQL in ABAP

    Is this format for Oracle?
      select *
       into -
       from  vbrk CLIENT SPECIFIED
    where erdat in erdat
        and mandt EQ sy-MANDT
        %_HINTS ORACLE 'INDEX("VBRK" "VBRK~ZER")'
    For the index 'VBRK~ZER' was defined before,it only includes one field 'VBRK-ERDAT'.
    How can i tell Sap to use this index while processing SQL in DB2?
    Thanks advance.

    There are different hints for the different database platforms.
    For up-to-date information please read the SAP notes, search 'hint DB2'.
    Siegfried

  • Getting error in indexing monitor for particular indexes

    Hi ,
    As i am currently using TREX search engine to search documents and i am facing an error in some of the indexes.
    Please find below screen shot of the error while clicking on error mode documents:
    Please suggest.
    Regards,
    Krunal Patel

    Hi Krunal,
    what's the application you use with TREX? Is it Enterprise Portal?
    Best regards,
    Mikhail

  • EL expression to set row at particular index as selected row

    Hi,
    What should be the EL expression to set row at index 'i' as selected row in a tree binding.
    I tried *#{bindings.treeBinding.collectionModel.selectedRow[i]}* . But it doesn't work.
    I also want to make the selected row as current. Will *#{bindings.treeBinding.collectionModel.makeCurrent}* work?
    Thanks
    KK

    Hi,
    create a managed bean that returns the selected RowKeys for the tree. See this example:
    http://www.oracle.com/technetwork/developer-tools/adf/learnmore/61search-in-rendered-trees-177577.pdf
    It searches for a specific label in a tree and marks it as selected
    Frank

  • After installing Lion my time machine using a Time capsule backups take a very long time, particularly indexing the back up, does any one know why and a fix?

    I have installed Lion over Snow Leopard and noticed a marked increase in the time it takes my time capsule/time machine to back up.  It seems to spend a very long time indexing the back up.  Does any one know why and more importantly is there a "fix"?

    The first index with Lion takes a very long time.  Could take over 10 hours.  You just have to wait.  You can see the progress by opening Console and entering backupd in the search box

  • Skipping only particular songs on particular albums

    I have a 4th gen. photo iPod. Recently I downloaded two Sigur Ross albums: () and Takk... Only one song on the ( ) album plays, but iPod just skips through the rest. The iPod will not play any songs on the Takk... album at all. I have restored the iPod once already, and it worked for the ( ) album, but when I downloaded the Takk... album, it went back to only playing the one song.
    The songs play fine in iTunes, though.
    Any help would be appreciated.
    Thanks,
    Jason

    I had the same problem and playlists aren't my preference because I want to manage my music using a check box in the main library window not a playlist. I struggled to get this to work because the wording is confusing in the new iTunes layout.
    Here's what you have to do (some are obvious but I'm being thorough):
    (I started by unselecting all my songs in my music library to start fresh with my iPod - if you already have your desired songs selected, the following steps should sync only the selected songs in your main library)
    1. Plug in your iPhone/iPod
    2. Click on the Summary button and check "sync only checked songs and videos" in the Options section
    3. Click Apply
    4. (Here's what got me) Click the Music button and check Entire music library NOT "Selected playlists, artists and genres"
    5. Click Apply if it shows, otherwise, click Sync
    Once you've set it up this way, you can add/remove music to your device by checking it in your main library screen.
    Hope this helps!

  • Skipping Album pages (Index links to Slideshow page)

    is there a way to do this?
    i'm using iweb '08 to set up an online portfolio of sorts. 4 main pages: main/home, resume, portfolio, contact info.
    the portfolio page will contain 4 albums of various types of art/design work and i'd like to skip the actual album page when you click on the album, instead taking you directly to the slideshow page. is this possible?

    I have been trying to do the same thing but haven't had any luck, there must be a way of deleting the page and making a link to the slide show.
    I was also trying to improve image quality iWeb seems to make the images very soft even if I pump up the sharpness it doesn't seem to make any difference.

  • How to skip a particular node in a script using test manager

    Hi,
    We are testing a script recorded for custom forms in R12 on two different instances using test manager.For one instance its running fine.
    But in the second instance one message note is not coming (one note which was present during recording is not there after the instance was refreshed). During Playback that node is not matching with recorded script so "object not found error is coming".Is there any way we can bypass that recording during playback through test manager ? Any kind of help is appreciated.
    Regards,
    Vishal

    Sorry for the inconvenience, Below Find detailed explanation of the issue,
    INSERT INTO XMLTABLE VALUES (4,'<?xml version="1.0"?>
    <Node_1 empID="202" empName="Pro1" oper="Update">
    <Node_2 empID="20" empName="Pro2" oper="Update">
    <Bode_3 empID="2" empName="Pro3" oper="Update">
    <Bode_4 empID="22" empName="Pro4" oper="Update">
    <Bode_5 empID="12" empName="Pro5" oper="Delete"/>
    <Bode_6 empID="223" empName="Pro6" oper="Insert"/>
    <Bode_7 empID="201" empName="Pro7" oper="All"/>
    <Node_3 empID="21" empName="Pro71" oper="ll">
    </Bode_4>
    </Bode_3>
    </Node_2>
    </Node_1>');
    I have a sequence seq_i
    seq_i start with 1 increment by 1
    am able to display output as below,
    Node|EMPID|OPER|EMPNAME|MGRID
    Node_1|202|Update|Pro1|Null
    Node_2|20|Update|Pro2|Node_1
    Bode_3|2|Update|Pro3|Node_2
    Bode_4|22|Update|Pro4|Bode_3
    Bode_5|12|Delete|Pro5|Bode_4
    Bode_6|223|Insert|Pro6|Bode_4
    Bode_7|201|All|Pro7|Bode_4
    Node_3|21|ll|Pro71|Bode_4
    Now I want below one as output
    All nodes starting with Bode_, I need to replace that with sequence, seq_i
    so for the seq_i (starting with i and incrementing by 1)
    Node|EMPID|OPER|EMPNAME|MGRID
    Node_1|202|Update|Pro1|Null
    Node_2|20|Update|Pro2|Node_1
    1|2|Update|Pro3|Node_2
    2|22|Update|Pro4|1
    3|12|Delete|Pro5|2
    4|223|Insert|Pro6|2
    5|201|All|Pro7|2
    Node_3|21|ll|Pro71|2
    Thanks,

  • Skipping an approver for particular requisition items - purchase requisitio

    In our purchase requisition approval heirarchy we want to skip one approver if it is a fixed asset , is it possible to conditionally forward documents, it has to happen automatically without user forwarding skipping the particular approver.

    AME (Approvals Management Engine) is available for purchasing in 11.5.10. I would strongly suggest implementing it for your requirement. AME is very flexible (I have created some very convoluted rules in invoice approvals.) Check out this thread for some ideas:
    {thread:id=944351}
    Without AME you are limited to creating a custom build approval group function for the workflow. I just got done doing that on 11.5.9 since AME for PO is not available in my version. Not a fun way to do it, but it worked.

  • Question about histograms and indexes

    I read that if a histogram is generated for a column and that column has an index then if the where clause contains a value that has a high cardinality the CBO will skip using the index. The article was with reference to the benefits of histograms.
    My question is: Why would the CBO skip using the index? Why not use it anyways? Is it because there is a cost associated with loading and using the index itself?
    Would appreciate some clarification on this, thanks!!!

    First, the article in question doesn't say to create histograms on columns with high cardinality values. A primary key column is going to be the ultimate in high cardinality columns (each value is unique after all) but it's rarely appropriate to create a histogram on that column. It does say that that histograms are generally useful when the data in a particular column is highly skewed-- that is, different values occur at wildly different rates.
    If you have a table of orders with an ORDER_STATUS column, for example, 95% of your orders may be CLOSED, 3% may be SHIPPING, and 1.9% may be IN PROCESS and 0.1% may be CANCELLED. Without a histogram, Oracle would take a look at that column and see that there were 4 distinct values, so it would assume an equal distribution across the statuses. Which would cause it to favor a full scan on the table even if you were looking just for the CANCELLED orders. With a histogram, the optimizer would favor an index on ORDER_STATUS for the cancelled query while still favoring a table scan if you're looking for closed orders.
    Gathering unnecessary histograms will make statistics collection take longer, which can cause issues with SLAs. It can also force you to gather statistics more frequently/ cause statistics to get out of date more quickly if you have monotonically increasing values in a column. If you have a CREATE_DATE column, for example, and gather a histogram, values that are greater than the max value at the time the histogram was gathered might be incorrectly estimated to be too infrequent, which can cause problems. If Oracle thinks that 1/6th of the rows are from Jan, 1/6 from Feb, etc. through June and you start looking for values from July because you haven't gathered statistics in a month, the CBO's estimates are going to be off. Unnecessary histograms also cause Oracle to spend more time parsing queries, potentially with no better results. And it can make troubleshooting a bit more difficult because, depending on the version and various optimizer settings, there may be multiple query plans for the same statement or different query plans depending on the particular bind variable that is first passed in.
    Justin

  • Column order in the index and its effects

    Lets say i've an index called ind_tab3 which is made up of two columns in the following order (col1,col2). If query comes against the table with WHERE clause like 'WHERE col2 =35' , will the ind_tab3 index be used. If this index is not used for this query, then what is the point of creating composite indexes? I know that an Index is created automatically for a primary key , which can be composite . So lets ignore this on our discussion.

    My point is:
    1) review every query on your system
    2) then choose an appropriate indexing strategy
    So if the col2 value is not used in an AND
    clause either, the ind_tab3 index wouldn't be
    used at all. Right?David replied to that. Index skip scan or index fast full scan MIGHT kick in.

  • IPod Nano skips certain songs

    My iPod Nano, version 1.0.2 Mac, model MD480LL, skips a handful of specific songs. When listening to music, one of these songs comes up for half a second and then skips to the next song, whether on shuffle or not. When I select one of these songs from the menu it does the same thing. These certain songs do not play on my iPod Nano at all. However, they play perfectly fine on my iMac, iPad, iPhone, and even my old 2nd gen iPod touch. My Nano is the only one that has this problem. I have tried restarting the Nano and restoring it, and the same songs still won't play. I've tried everything I could think of. I've serached through countless forums and have found many people with similar problems (but none exactly like mine) and I have tried every suggestion in each of these forums and none have helped. If you have any suggestions, any ideas at all, please don't hesitate to share.

    First off, does your iPod only skip on songs that you have purchased from the iTunes Store? Or does it vary from some of those purchases, to some songs from CD's you've imported?
    Also, does there seem to be a pattern, where your iPod only skips on particular songs, or is it ever-changing; for example, a few songs skipped yesterday, and now they don't skip anymore, but are replaced by different songs.
    Have you tried restoring your iPod? For more info, take a look here -> Restoring your iPod to Factory Settings
    If that attempt doesn't work, then try turning off your iPod's EQ settings.
    Go to "Settings > EQ" on your iPod. If you currently have a specific option set (i.e., "Treble Booster", "Vocal"), then try switching your setting to "Off".
    See if that changes anything.
    One last question: are the songs playing fine in iTunes, although they may not be playing well on your iPod?
    -Kylene
    If any post helps or solves your problem, please click the "Solved" or "Helpful" buttons on top of that post. Thank you for helping the boards!

Maybe you are looking for