WHEN TO USE LOGGER IN CREATE INDEX?

HI ALL,
WHEN TO USE LOGGER IN CREATE INDEX STATEMENT? AND WHEN TO USE NOLOGGING?
HOW IS INDEX PHYSICALLY STORED IN DATABASE?
THANKS IN ADVANCE.
SANDESH

NOLOGGING means that information is not written into the redo logs (relatively faster than LOGGING). However, this also means that if you need to recover your database, the index cannot be recovered (since the info cannot be found in the redo logs).
Use NOLOGGING if you need the speed (big indexes) and/or you don't care about being able to recover the index (i.e. if it is acceptable if you recreate it manually after possible database recovery). Alternatively, create the index with NOLOGGING, alter the index to LOGGING and backup the database. Only after the successfull backup will the index be recoverable (with that backup, not an older one).
Typically you should use LOGGING rather than NOLOGGING because the overhead of creating the backup/recovery and insecurity on being able to recover (and pressure that goes along with it) is to great. This option will be handy only in rare cases (e.g. when creating staging area tables/indexes in a datawarehouse. They don't need recovery and will therefore speed up when using NOLOGGING).
Hope this helps,
Lennert

Similar Messages

  • When I use Pages to create my newsletter, I get a small graphic in the header when I insert a page and I can't get rid of it.

    I use Pages to create the newsletter for a club that I belong to.  Just lately (within the last week) when I go to insert a page, I find a little graphic of a union jack in the header on the left side.  No matter what I do, I can not remove it!  Anyone else have this problem?

    You merge personalised details from either a Numbers spreadsheet set up correctly for the address fields or from your *Address Book*, where you can create a Group with your subscribers in it. When you drag a Group onto your Pages layout it generates as many copies as there are people in your Group.
    They will however all be in the same document, unless you manually drag each VCard individually to your layout and save that out to each name.
    You will then need to print each person's newsletter to a .pdf to insert into email.
    None of this is automated like in MsOffice. It would be best to look for a dedicated email distribution program at:
    http://www.macupdate.com
    Peter

  • When I use lightroom to create a slideshow the aspect ratio is wrong when i burn it to DVD.  What am i doing wrong?

    I use Lightroom to create a slideshow and then export it to software to burn to DVD to play on a TV.  When i view it on a computer the pictures are fine, when i view them on the TV the aspect ration is wrong.  Can anyone tell me what I'm doing wrong please?  Thanks

    The template is a document in itself, it is not applied to an existing document whether it is a Pages document or a Word document converted to a Pages document.
    You would need to either copy and paste content, using existing styles, or apply the styles to the converted Word document.
    You can Import the Styles from an existing document and those imported Styles can be used to override the current document's styles:
    Menu > Format > Import Styles
    The process is simplified if the styles use the same names, otherwise you will need to delete the style you don't want and replace it with the one that you do want when asked, then the substitution is pretty straightforward.
    Peter

  • Can I use Argo to create Indexes for Structured data?

    Hi, To search for employees who has stored some <i>word</i> in an infotype's text cluster takes time, specially when we also want those who has an relation in infotype 1001 to an object which again is connected to some other object where <i>word</i> appears in infotype 1002 - subtype 0001.
    Open SQL cannot select directly from text clusters, so we need to read all entries for all employees an the scan the entries for <i>word</i>. So an index which connects <i>word</i> or <i>this is a phrase</i> or  <i>department - description - all parent org.units</i> with employees would be nice to build to replace the open SQL.
    The question is if Argo is a solution to build, develope, store and administrate such indexes?
    Robert

    Hello Robert,
    Argo by itself does not index the content. Its our search engine TREX which does the indexing and searching.
    If you are using ERP 2005, quite a few objects are already indexed by TREX. We have a Framework services called SES (Search Engine Services) which expects you to implement couple of methods viz. 1) the data to index and b) any updates to the index. SES interacts with TREX to index the content.
    Regards,
    Bala.

  • Why can't I find the field remark when I use LSMW to create customer master

    I want to create customer master data with LSMW.
    Object               0050   客户主记录
    Method               0000
    Program Name         RFBIDE00
    Program Type         B   Batch Input
    but I can't find the field 'Comments' which is in view general data -> address.
    pls help me to find it.
    tks!

    Hi,
    This is quiet simple.
    See when you enter your Tcode in LSMW & start recording, on the first screen where you enter the customer details to create, you see a tick below "Use central adress management"
    Just tick this & record you will get comment in your recording
    Hope this helps you
    Regards,
    Dhananjay

  • Bug? Create Index can not edit index name

    Hi,
    when I want to create an index I can not edit the index name which is always tablename_index1 after I create the index with this name, delete it again and create a new one I can edit the indexname.
    this happens when you use the tabs in edit table. It works when you use context menu create index
    Regards, Juergen
    Message was edited by:
    Juergen.Schuster
    Message was edited by:
    Juergen.Schuster

    This seems to be specific to Oracle 9. I could not reproduce in 10 but did just reproduce in 9. The only way to get the index created was to refresh the connection, just refreshing the table or all tables did not do it. I will log a bug now.
    -- Sharon

  • Insufficient priviledge when creating index

    upon creating new indexes, using the command :
    create index im_art_s_idx_2 on article(cl_story)
    indextype is ctxsys.context;
    i get the following error :
    create index im_art_s_idx_2 on article(cl_story)
    ERROR at line 1:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE
    routine
    ORA-20000: interMedia Text error:
    ORA-01031: insufficient privileges
    ORA-06512: at "CTXSYS.DRUE", line 126
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 54
    ORA-06512: at line 1
    I can, however create normal indexes (i.e. by not specifying
    the indextype argument). Has anybody got any idea what this
    could be about?

    grant to user who's gonna create the index CTXAPP
    grant ctxapp to xxxx;

  • How to create  index for a column of a view

    Hi,
    I have created view for a table and then i am trying to create index for a column of that view. i am using the query "CREATE INDEX index_name ON view_name (col)". but Mysql is showing error like "view_name is not a base table".
    How can i do that......

    As mentioned this is a java forum not a mysql forum, but as I know the answer - you can't create an index directly on a view in mysql.

  • Wait Events "log file parallel write" / "log file sync" during CREATE INDEX

    Hello guys,
    at my current project i am performing some performance tests for oracle data guard. The question is "How does a LGWR SYNC transfer influences the system performance?"
    To get some performance values, that i can compare i just built up a normal oracle database in the first step.
    Now i am performing different tests like creating "large" indexes, massive parallel inserts/commits, etc. to get the bench mark.
    My database is an oracle 10.2.0.4 with multiplexed redo log files on AIX.
    I am creating an index on a "normal" table .. i execute "dbms_workload_repository.create_snapshot()" before and after the CREATE INDEX to get an equivalent timeframe for the AWR report.
    After the index is built up (round about 9 GB) i perform an awrrpt.sql to get the AWR report.
    And now take a look at these values from the AWR
                                                                       Avg
                                                 %Time  Total Wait    wait     Waits
    Event                                 Waits  -outs    Time (s)    (ms)      /txn
    log file parallel write              10,019     .0         132      13      33.5
    log file sync                           293     .7           4      15       1.0
    ......How can this be possible?
    Regarding to the documentation
    -> log file sync: http://download.oracle.com/docs/cd/B19306_01/server.102/b14237/waitevents003.htm#sthref3120
    Wait Time: The wait time includes the writing of the log buffer and the post.-> log file parallel write: http://download.oracle.com/docs/cd/B19306_01/server.102/b14237/waitevents003.htm#sthref3104
    Wait Time: Time it takes for the I/Os to complete. Even though redo records are written in parallel, the parallel write is not complete until the last I/O is on disk.This was also my understanding .. the "log file sync" wait time should be higher than the "log file parallel write" wait time, because of it includes the I/O and the response time to the user session.
    I could accept it, if the values are close to each other (maybe round about 1 second in total) .. but the different between 132 seconds and 4 seconds is too noticeable.
    Is the behavior of the log file sync/write different when performing a DDL like CREATE INDEX (maybe async .. like you can influence it with the initialization parameter COMMIT_WRITE??)?
    Do you have any idea how these values come about?
    Any thoughts/ideas are welcome.
    Thanks and Regards

    Surachart Opun (HunterX) wrote:
    Thank you for Nice Idea.
    In this case, How can we reduce "log file parallel write" and "log file sync" waited time?
    CREATE INDEX with NOLOGGINGA NOLOGGING can help, can't it?Yes - if you create index nologging then you wouldn't be generating that 10GB of redo log, so the waits would disappear.
    Two points on nologging, though:
    <ul>
    it's "only" an index, so you could always rebuild it in the event of media corruption, but if you had lots of indexes created nologging this might cause an unreasonable delay before the system was usable again - so you should decide on a fallback option, such as taking a new backup of the tablespace as soon as all the nologging operatons had completed.
    If the database, or that tablespace, is in +"force logging"+ mode, the nologging will not work.
    </ul>
    Don't get too alarmed by the waits, though. My guess is that the +"log file sync"+ waits are mostly from other sessions, and since there aren't many of them the other sessions are probably not seeing a performance issue. The +"log file parallel write"+ waits are caused by your create index, but they are happeninng to lgwr in the background which is running concurrently with your session - so your session is not (directly) affected by them, so may not be seeing a performance issue.
    The other sessions are seeing relatively high sync times because their log file syncs have to wait for one of the large writes that you have triggered to complete, and then the logwriter includes their (little) writes with your next (large) write.
    There may be a performance impact, though, from the pure volume of I/O. Apart from the I/O to write the index you have LGWR writting (N copies) of the redo for the index and ARCH is reading and writing the completed log files caused by the index build. So the 9GB of index could easily be responsible for vastly more I/O than the initial 9GB.
    Regards
    Jonathan Lewis
    http://jonathanlewis.wordpress.com
    http://www.jlcomp.demon.co.uk
    To post code, statspack/AWR report, execution plans or trace files, start and end the section with the tag {noformat}{noformat} (lowercase, curly brackets, no spaces) so that the text appears in fixed format.
    "Science is more than a body of knowledge; it is a way of thinking"
    Carl Sagan                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • "Non rectangular objects will not appear correctly when exported using CSS."

    I am using Ind CC 2014 exporting a document to a reflowable epub.  The document contains an .ai image.  The image exports correctly in some parts of the.epub but not others, where it is distorted. There is a warning on export :"Non rectangular objects will not appear correctly when exported using CSS."  Any suggestions appreciated.

    Thanks!
    >
          "Non rectangular objects will not appear correctly when exported
          using CSS."
    created by pooja2087 <https://forums.adobe.com/people/pooja2087> in
    /InDesign EPUB/ - View the full discussion
    <https://forums.adobe.com/message/6886892#6886892>

  • How to use LT03 to create TO by WBS delivery

    Hi,
    I have a WBS delivery, when I use LT03 to create a TO by this delivery, I can see the WBS field is empty, and gray. how to let me go ahead to create a WBS TO?
    Thanks.

    If the LIPS fields don't have the special stock data, then your delivery is not related to special stock. Consequently, the TO cannot have special stock data too.
    If you expected that project stock should be picked and issued through the delivery, it's better you check the preceding documents, master data and configuration, something may have gone wrong.

  • Creating index using XMLIndex, changes the result set when querying

    Hi there,
    I was tasked with populating an Oracle 11Gr2 database with data from 800,000 XML files. I used the Oracle documentation, and in about 2 days I had the data loaded into a simple table.
    Queries of this table were SLOW, so this morning I read about using XMLIndex to index the table... I did this, and it works great -- the queries got a LOT faster.
    However -- a "column" from my XML data is supposed to return values of 2000-4000 characters. It worked fine, until I created my index -- after I created the XMLIndex, the data is being truncated to 80 chars in my query.
    CREATE TABLE TEST_XMLTABLE OF XMLType; /* XML data has a "node" called TEXT which can be up to 4000 chars */
    SELECT to_number( extractValue(OBJECT_VALUE, 'newsitem/@itemid')) as ITEM_ID, Text.text <----- value here will contain full text body up to 4k chars
    FROM TEST_XMLTABLE KTX,
    XMLTABLE('/newsitem' PASSING ktx.Object_Value columns "TEXT" clob PATH 'text') TEXT
    /* now create the index */
    CREATE INDEX IDX_xmlindex ON TEST_XMLTABLE (OBJECT_VALUE) INDEXTYPE IS XDB.XMLIndex;
    Now, run my query again, and TEXT.TEXT is truncated to only 80 chars!?!?!
    I'm not sure what to do next... my users need the full text, so for now I have dropped the XMLIndex... the queries are slow, but they are getting all the data.
    Thanks in advance for any help or ideas.
    Keith

    I still do not have an answer back from Oracle, regarding if this is a "bug" or not....
    but for now, I have a "workaround" that seems to fix the problem. After I create the XMLIndex, I can remove the troublesome "path" from the index by doing an index rebuild, as shown:
    ALTER INDEX IDX_xmlindex REBUILD PARAMETERS ('PATHS (EXCLUDE ADD (/newsitem/text))');
    After I rebulld the index, I get all the chars in my TEXT node properly. However, the performance of the queries is noticably slower than before I did the ALTER INDEX.. albeit still faster than with no index at all.

  • Why CBO don't use function-base index when I use like and bind variable

    Hello
    I have litle problem with function-base index and like with bind variable.
    When I use like with bind variable, the CBO don't use my function-base index.
    For example when I create table and index:
    ALTER SESSION SET NLS_SORT='BINARY_CI';
    ALTER SESSION SET NLS_COMP='LINGUISTIC';
    alter session set nls_language='ENGLISH';
    -- DROP TABLE TEST1;
    CREATE TABLE TEST1 (K1 VARCHAR2(32));
    create index test1_idx on test1(nlssort(K1,'nls_sort=BINARY_CI'));
    INSERT INTO TEST1
    SELECT OBJECT_NAME FROM ALL_OBJECTS;
    COMMIT;
    When I run:
    ALTER SESSION SET NLS_SORT='BINARY_CI';
    ALTER SESSION SET NLS_COMP='LINGUISTIC';
    SELECT * FROM TEST1 WHERE K1 = 'abcd';
    or
    SELECT * FROM TEST1 WHERE K1 LIKE 'abcd%';
    CBO use index.
    PLAN_TABLE_OUTPUT
    SQL_ID 4vrmp7cshbvqy, child number 1
    SELECT * FROM TEST1 WHERE K1 LIKE 'abcd%'
    Plan hash value: 1885706448
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
    | 0 | SELECT STATEMENT | | | | 1 (100)| |
    | 1 | TABLE ACCESS BY INDEX ROWID| TEST1 | 2 | 98 | 1 (0)| 00:00:01 |
    |* 2 | INDEX RANGE SCAN | TEST1_IDX | 2 | | 1 (0)| 00:00:01 |
    Predicate Information (identified by operation id):
    2 - access("TEST1"."SYS_NC00002$">=HEXTORAW('6162636400') AND
    "TEST1"."SYS_NC00002$"<HEXTORAW('6162636500') )
    but when I run
    SELECT * FROM TEST1 WHERE K1 LIKE :1;
    CBO don't use index
    PLAN_TABLE_OUTPUT
    SQL_ID 9t461s1669gru, child number 0
    SELECT * FROM TEST1 WHERE K1 LIKE :1
    Plan hash value: 4122059633
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
    | 0 | SELECT STATEMENT | | | | 89 (100)| |
    |* 1 | TABLE ACCESS FULL| TEST1 | 2 | 48 | 89 (3)| 00:00:02 |
    Predicate Information (identified by operation id):
    1 - filter("K1" LIKE :1)
    What should I change to force CBO to use index.
    I don't wont use index hint in query.
    My oracle version:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    PL/SQL Release 11.2.0.1.0 - Production
    CORE     11.2.0.1.0     Production
    TNS for 64-bit Windows: Version 11.2.0.1.0 - Production
    NLSRTL Version 11.2.0.1.0 - Production

    OK. But why if I create normal index (create index test1_idx on test1(K1)) and return to default nls settings this same query use index.
    PLAN_TABLE_OUTPUT
    SQL_ID 9t461s1669gru, child number 0
    SELECT * FROM TEST1 WHERE K1 LIKE :1
    Plan hash value: 598212486
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
    | 0 | SELECT STATEMENT | | | | 1 (100)| |
    |* 1 | INDEX RANGE SCAN| TEST1_IDX | 1 | 18 | 1 (0)| 00:00:01 |
    Predicate Information (identified by operation id):
    1 - access("K1" LIKE :1)
    filter("K1" LIKE :1)
    Note
    - dynamic sampling used for this statement (level=2)
    when index is function-base (create index test1_idx on test1(nlssort(K1,'nls_sort=BINARY_CI')))
    PLAN_TABLE_OUTPUT
    SQL_ID 9t461s1669gru, child number 1
    SELECT * FROM TEST1 WHERE K1 LIKE :1
    Plan hash value: 4122059633
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
    | 0 | SELECT STATEMENT | | | | 89 (100)| |
    |* 1 | TABLE ACCESS FULL| TEST1 | 3 | 54 | 89 (3)| 00:00:02 |
    Predicate Information (identified by operation id):
    1 - filter("K1" LIKE :1)
    Note
    - dynamic sampling used for this statement (level=2)
    when I create index with upper function "index test1_idx on test1(upper(K1))" the query use index
    SELECT * FROM TEST1 WHERE upper(K1) LIKE :1
    Plan hash value: 1885706448
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
    | 0 | SELECT STATEMENT | | | | 1 (100)| |
    | 1 | TABLE ACCESS BY INDEX ROWID| TEST1 | 4481 | 157K| 1 (0)| 00:00:01 |
    |* 2 | INDEX RANGE SCAN | TEST1_IDX | 806 | | 1 (0)| 00:00:01 |
    Predicate Information (identified by operation id):
    2 - access("TEST1"."SYS_NC00002$" LIKE :1)
    filter("TEST1"."SYS_NC00002$" LIKE :1)
    Note
    - dynamic sampling used for this statement (level=2)

  • Newly created index not being used

    Hello friends,
    I am observing that a newly created index on a z table with mandt & a new field is not being used. I have already rebuild index & updated stats for table.
    when we query on this table with where clause having same 2 fields mandt & other.. we expected this index to be used. This table is very large. What more i can do now ?
    In trace/SQL session, we can see it is going full table scan.. and takes very long time.
    this new field contain no data as of now for all existing rows. Is this the reason ? or sometihng else ?
    SQL Statement
    SELECT
    FROM
      "ABSA"
    WHERE
      "MANDT" = :A0 AND "ZABCD" = :A1
    Execution Plan
    Explain from v$sql_plan not possible ->  Explain from PLAN_TABLE is displayed !
    No values in v$sql_plan for Address: 0000000166710240 Hash_value:  3891403872 Child_number:  0 Sql_id:
    SELECT STATEMENT ( Estimated Costs = 905.739 , Estimated #Rows = 110.190.667 )
            1 TABLE ACCESS FULL ZABSA
              ( Estim. Costs = 905.739 , Estim. #Rows = 110.190.667 )
              Estim. CPU-Costs = 152.614.535.266 Estim. IO-Costs = 899.784
              Filter Predicates
    NONUNIQUE  Index   ZABSA~Z01
    Column Name                     #Distinct
    MANDT                                          1
    ZABCD                                         1
    thanks & regards
    ashish
    Edited by: ashish vikas on Mar 3, 2012 9:05 PM

    ashish vikas wrote:
    > Execution Plan
    > Explain from v$sql_plan not possible ->  Explain from PLAN_TABLE is displayed !
    > No values in v$sql_plan for Address: 0000000166710240 Hash_value:  3891403872 Child_number:  0 Sql_id:
    >
    >  SELECT STATEMENT ( Estimated Costs = 905.739 , Estimated #Rows = 110.190.667 )
    >
    >         1 TABLE ACCESS FULL ZABSA
    >           ( Estim. Costs = 905.739 , Estim. #Rows = 110.190.667 )
    >           Estim. CPU-Costs = 152.614.535.266 Estim. IO-Costs = 899.784
    >           Filter Predicates
    >
    > NONUNIQUE  Index   ZABSA~Z01
    > Column Name                     #Distinct
    > MANDT                                          1
    > ZABCD                                         1
    Hi,
    with this WHERE clause, both columns just one distinct value, the Full Table Scan is indded the best approach, beside
    the point you only need a check to evaluate a value is NOT in the result.
    In this case you should HINT the statement to the new index, because the DB will always assume that this index is non-selective.
    Volker

  • What resources are used for "create index" ?

    In the context of creating an index on a heavily loaded table....
    What Oracle resources are consumed>? Any caches or buffers? Sort files? Temp Tables?
    (trying to speed up an index create)

    Like any other read/write database activities, CREATE INDEX uses blocks in the buffer cache. If your table is large, I would recommend increase your buffer cache.
    No temporary tables is used as far as I know. There are no sort files in Oracle. Temporary tablespace may be used because sorting is generally needed when creating an index, but I am not sure about that.
    When creating a index, Oracle creates a temporary segment in your permanent tablespace: if the CREATE INDEX fails, the temporary segment is removed. If the CREATE INDEX succeeds, the temporary segment is made permanent.
    Message was edited by:
    Pierre Forstmann

Maybe you are looking for

  • Can't click links??

    Hey. I just recently bought a new BB Curve 8530 from Koodo and i'm not able to click any links. I received pictures where I have to click a link but it's just text, no hyperlink. Also I went to download some apps and I had to click a link in my hotma

  • My iphone doesn't accept my sim-cart! How can i activate it??

    hello, i have an iphone and an e-plus sim-cart.. how can i activate it???

  • CSS -- background color doesn't show with scroll bar

    I have a nav bar with a background-color that shows up fine if the image opens to the right size.  If, however, the window opens small and I have to use the scroll bar to move things over, the color for the nav bar isn't there. Any thoughts would be

  • Air + Ipad + RemoteObject problem with session cookies

    I am making Air version for IPad of a Flex application. My flex application needs session from an secured enterprise proxy, without that session none remoteObject requests can pass the proxy and reach blazeDS. My solution for flex works fine: calling

  • [CS5][Save for Web][Anti-aliasing] Fine lines in exported PSD with adjustment layers

    Hello, You can reproduce the bug this way: - link a PSD with a adjustment (Levels, Brightness/Contrast) layer in your AI file - Save for Web, with AA for Art (not text) selected In the exported image there will be artefacts, white lines usually. Flat