If I drop table, am also fall the index which belong to this table?

for example:

create table TBL_A (FIELD_A1 number not null,

FIELD_A2 varchar2 (50).

Date of FIELD_A3,

FIELD_A4 number (5.2) default 0,

FIELD_A5 varchar2 (10) not null

);

create a unique index XPKTBL_A on TBL_A (FIELD_A1);



drop table TBL_A;


What is the syntax for deleting indexes in oracle?


delete the index XPKTBL_A - is this correct?



If I drop table, am also fall the index which belong to this table?

Yes.

Tags: Database

Similar Questions

  • Formatting of 'see' or 'see also' in the index

    Using FM 8.0p277 on Windows XP (required by the customer).

    The Chicago Manual of Style italic clamoring for the words 'See' or 'See also' in the index. For example, an index entry can be "Puppy. See Dog. "I can not find how to make these words in italics in the index entries. Is this possible?

    Thank you very much

    -Gloria Mc

    You have entered the character for the italics tag in your marker?

    See: http://help.adobe.com/en_US/FrameMaker/8.0/Chap12-TOC-Indexes_22.html

  • DROP TABLE performance

    Hello

    could someone share advice on improving the execution time of the abandonment of the tables?

    I have a blank table with more than 200 columns and it takes 23-25 s to drop. Smaller tables take something around 0.1 s of course. Problem is I have let fall from thousands of these tables and then re-create them. The recreate itself takes not more than one second.

    What is the origin of more time? Is it because of an implicit validation in the drop table command?

    I tried this with almost identical times noarchivelog mode. I also tried different settings and commit_logging optimizer_mode, none showed any usable results, but I'm still at the experimental stage. The goal is to minimize the execution time once I need to run the entire batch, perhaps in the course of running several sessions can work to be faster (while times are maybe longer), don't know yet.

    Here is an example of output:
    SQL> CREATE TABLE "SYSADM"."DRIVERTEST"
      2    (
      3      "PROCESS_INSTANCE"   NUMBER(10,0) NOT NULL ENABLE,
      4      "INTFC_ID"           NUMBER(*,0) NOT NULL ENABLE,
      5      "INTFC_LINE_NUM"     NUMBER(*,0) NOT NULL ENABLE,
      6      "TRANS_TYPE_BI"      VARCHAR2(4 CHAR) NOT NULL ENABLE,
      7      "TRANS_TYPE_BI_SEQ"  NUMBER(*,0) NOT NULL ENABLE,
      8      "HDR_FIELDS_KEY"     VARCHAR2(30 CHAR) NOT NULL ENABLE,
      9      "HDR_FIELDS_BILL_BY" VARCHAR2(1 CHAR) NOT NULL ENABLE,
     10      "ADJ_TRANS_TYPE"     VARCHAR2(5 CHAR) NOT NULL ENABLE,
     11      "CREATE_NEW_BILL"    VARCHAR2(1 CHAR) NOT NULL ENABLE,
     12      "TMP_BILL_FLG"       VARCHAR2(1 CHAR) NOT NULL ENABLE,
     13      "ENTRY_TYPE"         VARCHAR2(5 CHAR) NOT NULL ENABLE,
     14      "ENTRY_REASON"       VARCHAR2(5 CHAR) NOT NULL ENABLE,
     15      "ENTRY_EVENT"        VARCHAR2(10 CHAR) NOT NULL ENABLE,
     16      "LOAD_STATUS_BI"     VARCHAR2(3 CHAR) NOT NULL ENABLE,
     17      "ERROR_STATUS_BI"    VARCHAR2(4 CHAR) NOT NULL ENABLE,
     18      "BUSINESS_UNIT"      VARCHAR2(5 CHAR) NOT NULL ENABLE,
     19      "BUSINESS_UNIT_GL"   VARCHAR2(5 CHAR) NOT NULL ENABLE,
     20      "BILL_TO_CUST_ID"    VARCHAR2(15 CHAR) NOT NULL ENABLE,
     21      "ADDRESS_SEQ_NUM"    NUMBER(*,0) NOT NULL ENABLE,
     22      "BILL_TO_COPIES"     NUMBER(*,0) NOT NULL ENABLE,
     23      "CNTCT_SEQ_NUM"      NUMBER(*,0) NOT NULL ENABLE,
     24      "NAME1"              VARCHAR2(40 CHAR) NOT NULL ENABLE,
     25      "INTERUNIT_FLG"      VARCHAR2(1 CHAR) NOT NULL ENABLE,
     26      "BUSINESS_UNIT_TO"   VARCHAR2(5 CHAR) NOT NULL ENABLE,
     27      "DIRECT_INVOICING"   VARCHAR2(1 CHAR) NOT NULL ENABLE,
     28      "RANGE_SELECTION_ID" VARCHAR2(30 CHAR) NOT NULL ENABLE,
     29      "BILL_SOURCE_ID"     VARCHAR2(10 CHAR) NOT NULL ENABLE,
     30      "BILL_TYPE_ID"       VARCHAR2(3 CHAR) NOT NULL ENABLE,
     31      "BILL_CYCLE_ID"      VARCHAR2(10 CHAR) NOT NULL ENABLE,
     32      "BILL_BY_ID"         VARCHAR2(10 CHAR) NOT NULL ENABLE,
     33      "PAYMENT_METHOD"     VARCHAR2(3 CHAR) NOT NULL ENABLE,
     34      "PYMNT_TERMS_CD"     VARCHAR2(5 CHAR) NOT NULL ENABLE,
     35      "BANK_CD"            VARCHAR2(5 CHAR) NOT NULL ENABLE,
     36      "BANK_ACCT_KEY"      VARCHAR2(4 CHAR) NOT NULL ENABLE,
     37      "BI_CURRENCY_CD"     VARCHAR2(3 CHAR) NOT NULL ENABLE,
     38      "BASE_CURRENCY"      VARCHAR2(3 CHAR) NOT NULL ENABLE,
     39      "CUR_RT_TYPE"        VARCHAR2(5 CHAR) NOT NULL ENABLE,
     40      "RATE_MULT"          NUMBER(15,8) NOT NULL ENABLE,
     41      "RATE_DIV"           NUMBER(15,8) NOT NULL ENABLE,
     42      "CUR_RT_SOURCE"      VARCHAR2(1 CHAR) NOT NULL ENABLE,
     43      "INVOICE_DT" DATE,
     44      "ACCOUNTING_DT" DATE,
     45      "ACCRUE_UNBILLED"    VARCHAR2(1 CHAR) NOT NULL ENABLE,
     46      "TARGET_INVOICE"     VARCHAR2(22 CHAR) NOT NULL ENABLE,
     47      "INVOICE"            VARCHAR2(22 CHAR) NOT NULL ENABLE,
     48      "DOC_TYPE"           VARCHAR2(8 CHAR) NOT NULL ENABLE,
     49      "CONSOL_SETID"       VARCHAR2(5 CHAR) NOT NULL ENABLE,
     50      "CONSOL_CUST_ID"     VARCHAR2(15 CHAR) NOT NULL ENABLE,
     51      "CONSOL_KEY"         VARCHAR2(22 CHAR) NOT NULL ENABLE,
     52      "INVOICE_TO_ADJ"     VARCHAR2(22 CHAR) NOT NULL ENABLE,
     53      "ADJ_DELTA_ACTION"   VARCHAR2(3 CHAR) NOT NULL ENABLE,
     54      "LINE_SEQ_TO_ADJ"    NUMBER(*,0) NOT NULL ENABLE,
     55      "LINE_SEQ_NUM"       NUMBER(*,0) NOT NULL ENABLE,
     56      "LINE_DST_SEQ_NUM"   NUMBER(*,0) NOT NULL ENABLE,
     57      "LINE_DFR_SEQ_NUM"   NUMBER(*,0) NOT NULL ENABLE,
     58      "LINE_UAR_SEQ_NUM"   NUMBER(*,0) NOT NULL ENABLE,
     59      "LAST_NOTE_SEQ_NUM"  NUMBER(*,0) NOT NULL ENABLE,
     60      "NOTES_SEQ_NUM"      NUMBER(*,0) NOT NULL ENABLE,
     61      "LINE_TYPE"          VARCHAR2(4 CHAR) NOT NULL ENABLE,
     62      "IDENTIFIER"         VARCHAR2(18 CHAR) NOT NULL ENABLE,
     63      "DESCR"              VARCHAR2(30 CHAR) NOT NULL ENABLE,
     64      "UNIT_OF_MEASURE"    VARCHAR2(3 CHAR) NOT NULL ENABLE,
     65      "QTY"                NUMBER(15,4) NOT NULL ENABLE,
     66      "ORIG_QTY"           NUMBER(15,4) NOT NULL ENABLE,
     67      "UNIT_AMT"           NUMBER(15,4) NOT NULL ENABLE,
     68      "LIST_PRICE"         NUMBER(15,4) NOT NULL ENABLE,
     69      "PPRC_PROMO_CD"      VARCHAR2(20 CHAR) NOT NULL ENABLE,
     70      "MERCH_TYPE"         VARCHAR2(10 CHAR) NOT NULL ENABLE,
     71      "TAX_CD"             VARCHAR2(8 CHAR) NOT NULL ENABLE,
     72      "TAX_EXEMPT_CERT"    VARCHAR2(30 CHAR) NOT NULL ENABLE,
     73      "TAX_EXEMPT_FLG"     VARCHAR2(1 CHAR) NOT NULL ENABLE,
     74      "TAX_EXEMPT_RC"      VARCHAR2(2 CHAR) NOT NULL ENABLE,
     75      "TAX_JOB_NUM"        VARCHAR2(10 CHAR) NOT NULL ENABLE,
     76      "BI_TAX_TIMING"      VARCHAR2(1 CHAR) NOT NULL ENABLE,
     77      "CUSTOMER_GROUP"     VARCHAR2(10 CHAR) NOT NULL ENABLE,
     78      "VAT_TXN_TYPE_CD"    VARCHAR2(4 CHAR) NOT NULL ENABLE,
     79      "TAX_CD_VAT"         VARCHAR2(8 CHAR) NOT NULL ENABLE,
     80      "VAT_APPLICABILITY"  VARCHAR2(1 CHAR) NOT NULL ENABLE,
     81      "VAT_PRODUCT_GROUP"  VARCHAR2(10 CHAR) NOT NULL ENABLE,
     82      "PROD_GRP_SETID"     VARCHAR2(5 CHAR) NOT NULL ENABLE,
     83      "IST_TXN_FLG"        VARCHAR2(1 CHAR) NOT NULL ENABLE,
     84      "IDENTIFIER_TBL"     VARCHAR2(3 CHAR) NOT NULL ENABLE,
     85      "SHIP_FROM_LOC"      VARCHAR2(10 CHAR) NOT NULL ENABLE,
     86      "ORD_ACCEPT_LOC"     VARCHAR2(10 CHAR) NOT NULL ENABLE,
     87      "ORD_ORIGIN_LOC"     VARCHAR2(10 CHAR) NOT NULL ENABLE,
     88      "STORE_LOC"          VARCHAR2(10 CHAR) NOT NULL ENABLE,
     89      "TITLE_PASSAGE"      VARCHAR2(1 CHAR) NOT NULL ENABLE,
     90      "TAX_GROUP"          VARCHAR2(10 CHAR) NOT NULL ENABLE,
     91      "TAX_USER_AREA"      VARCHAR2(25 CHAR) NOT NULL ENABLE,
     92      "TAX_TRANS_TYPE"     VARCHAR2(1 CHAR) NOT NULL ENABLE,
     93      "TAX_TRANS_SUB_TYPE" VARCHAR2(1 CHAR) NOT NULL ENABLE,
     94      "NET_EXTENDED_AMT"   NUMBER(26,3) NOT NULL ENABLE,
     95      "GROSS_EXTENDED_AMT" NUMBER(26,3) NOT NULL ENABLE,
     96      "REV_RECOG_BASIS"    VARCHAR2(3 CHAR) NOT NULL ENABLE,
     97      "PROJECT_ID"         VARCHAR2(15 CHAR) NOT NULL ENABLE,
     98      "BUSINESS_UNIT_OM"   VARCHAR2(5 CHAR) NOT NULL ENABLE,
     99      "ORDER_NO"           VARCHAR2(10 CHAR) NOT NULL ENABLE,
    100      "ORDER_INT_LINE_NO"  NUMBER(*,0) NOT NULL ENABLE,
    101      "SCHED_LINE_NBR"     NUMBER(*,0) NOT NULL ENABLE,
    102      "DEMAND_SOURCE"      VARCHAR2(2 CHAR) NOT NULL ENABLE,
    103      "DEMAND_LINE_NO"     NUMBER(*,0) NOT NULL ENABLE,
    104      "BUSINESS_UNIT_RMA"  VARCHAR2(5 CHAR) NOT NULL ENABLE,
    105      "RMA_ID"             VARCHAR2(10 CHAR) NOT NULL ENABLE,
    106      "RMA_LINE_NBR"       NUMBER(*,0) NOT NULL ENABLE,
    107      "PRODUCT_ID"         VARCHAR2(18 CHAR) NOT NULL ENABLE,
    108      "ORDER_DATE" DATE,
    109      "PO_REF"       VARCHAR2(30 CHAR) NOT NULL ENABLE,
    110      "PO_LINE"      NUMBER(*,0) NOT NULL ENABLE,
    111      "CONTRACT_NUM" VARCHAR2(25 CHAR) NOT NULL ENABLE,
    112      "CONTRACT_DT" DATE,
    113      "CONTRACT_TYPE"     VARCHAR2(15 CHAR) NOT NULL ENABLE,
    114      "CONTRACT_LINE_NUM" NUMBER(*,0) NOT NULL ENABLE,
    115      "FREIGHT_TERMS"     VARCHAR2(10 CHAR) NOT NULL ENABLE,
    116      "BILL_OF_LADING"    VARCHAR2(30 CHAR) NOT NULL ENABLE,
    117      "COUNTRY_SHIP_FROM" VARCHAR2(3 CHAR) NOT NULL ENABLE,
    118      "COUNTRY_SHIP_TO"   VARCHAR2(3 CHAR) NOT NULL ENABLE,
    119      "SHIP_TO_CUST_ID"   VARCHAR2(15 CHAR) NOT NULL ENABLE,
    120      "SHIP_TO_ADDR_NUM"  NUMBER(*,0) NOT NULL ENABLE,
    121      "SHIP_ID"           VARCHAR2(10 CHAR) NOT NULL ENABLE,
    122      "SHIP_TYPE_ID"      VARCHAR2(10 CHAR) NOT NULL ENABLE,
    123      "SHIP_FROM_BU"      VARCHAR2(5 CHAR) NOT NULL ENABLE,
    124      "SHIP_DATE" DATE,
    125      "SHIP_TIME" TIMESTAMP (6),
    126      "PACKSLIP_NO"      VARCHAR2(22 CHAR) NOT NULL ENABLE,
    127      "LC_ID"            VARCHAR2(12 CHAR) NOT NULL ENABLE,
    128      "LOC_DOC_ID"       VARCHAR2(15 CHAR) NOT NULL ENABLE,
    129      "SEQUENCE_NBR"     NUMBER(*,0) NOT NULL ENABLE,
    130      "SOLD_TO_CUST_ID"  VARCHAR2(15 CHAR) NOT NULL ENABLE,
    131      "SOLD_TO_ADDR_NUM" NUMBER(*,0) NOT NULL ENABLE,
    132      "BUSINESS_UNIT_PC" VARCHAR2(5 CHAR) NOT NULL ENABLE,
    133      "BUSINESS_UNIT_CA" VARCHAR2(5 CHAR) NOT NULL ENABLE,
    134      "RT_EFFDT" DATE,
    135      "BILL_PLAN_ID"      VARCHAR2(10 CHAR) NOT NULL ENABLE,
    136      "PC_DISTRIB_STATUS" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    137      "BPLAN_LN_NBR"      NUMBER(*,0) NOT NULL ENABLE,
    138      "EVENT_OCCURRENCE"  NUMBER(*,0) NOT NULL ENABLE,
    139      "XREF_SEQ_NUM"      NUMBER(*,0) NOT NULL ENABLE,
    140      "CONTRACT_PPD_SEQ"  NUMBER(*,0) NOT NULL ENABLE,
    141      "ANALYSIS_TYPE"     VARCHAR2(3 CHAR) NOT NULL ENABLE,
    142      "RESOURCE_ID"       VARCHAR2(40 CHAR) NOT NULL ENABLE,
    143      "RESOURCE_TYPE"     VARCHAR2(5 CHAR) NOT NULL ENABLE,
    144      "RESOURCE_CATEGORY" VARCHAR2(5 CHAR) NOT NULL ENABLE,
    145      "RESOURCE_SUB_CAT"  VARCHAR2(5 CHAR) NOT NULL ENABLE,
    146      "ACTIVITY_ID"       VARCHAR2(15 CHAR) NOT NULL ENABLE,
    147      "ACTIVITY_TYPE"     VARCHAR2(5 CHAR) NOT NULL ENABLE,
    148      "DIST_CFG_FLAG"     VARCHAR2(1 CHAR) NOT NULL ENABLE,
    149      "PRODUCT_KIT_ID"    VARCHAR2(18 CHAR) NOT NULL ENABLE,
    150      "SYSTEM_SOURCE"     VARCHAR2(3 CHAR) NOT NULL ENABLE,
    151      "EMPLID"            VARCHAR2(11 CHAR) NOT NULL ENABLE,
    152      "EMPL_RCD"          NUMBER(*,0) NOT NULL ENABLE,
    153      "START_DT" DATE,
    154      "END_DT" DATE,
    155      "FROM_DT" DATE,
    156      "TO_DT" DATE,
    157      "SERVICE_CUST_ID"    VARCHAR2(15 CHAR) NOT NULL ENABLE,
    158      "SERVICE_ADDR_NUM"   NUMBER(*,0) NOT NULL ENABLE,
    159      "NOTE_TYPE"          VARCHAR2(10 CHAR) NOT NULL ENABLE,
    160      "STD_NOTE_FLAG"      VARCHAR2(1 CHAR) NOT NULL ENABLE,
    161      "INTERNAL_FLAG"      VARCHAR2(1 CHAR) NOT NULL ENABLE,
    162      "HDR_OR_LINE_NOTE"   VARCHAR2(1 CHAR) NOT NULL ENABLE,
    163      "AR_LVL"             VARCHAR2(1 CHAR) NOT NULL ENABLE,
    164      "AR_DST_OPT"         VARCHAR2(1 CHAR) NOT NULL ENABLE,
    165      "GL_LVL"             VARCHAR2(1 CHAR) NOT NULL ENABLE,
    166      "ENABLE_DFR_REV_FLG" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    167      "BILLING_SPECIALIST" VARCHAR2(8 CHAR) NOT NULL ENABLE,
    168      "BILLING_AUTHORITY"  VARCHAR2(8 CHAR) NOT NULL ENABLE,
    169      "BILLING_FREQUENCY"  VARCHAR2(3 CHAR) NOT NULL ENABLE,
    170      "BILL_INQUIRY_PHONE" VARCHAR2(24 CHAR) NOT NULL ENABLE,
    171      "SALES_PERSON"       VARCHAR2(8 CHAR) NOT NULL ENABLE,
    172      "COLLECTOR"          VARCHAR2(8 CHAR) NOT NULL ENABLE,
    173      "CR_ANALYST"         VARCHAR2(8 CHAR) NOT NULL ENABLE,
    174      "INVOICE_FORM_ID"    VARCHAR2(10 CHAR) NOT NULL ENABLE,
    175      "STD_NOTE_CD"        VARCHAR2(10 CHAR) NOT NULL ENABLE,
    176      "TOT_LINE_DST_AMT"   NUMBER(26,3) NOT NULL ENABLE,
    177      "TOT_LINE_DST_PCT"   NUMBER(5,2) NOT NULL ENABLE,
    178      "TOT_LINE_DFR_PCT"   NUMBER(5,2) NOT NULL ENABLE,
    179      "TOT_LINE_DFR_AMT"   NUMBER(26,3) NOT NULL ENABLE,
    180      "TOT_LINE_UAR_AMT"   NUMBER(26,3) NOT NULL ENABLE,
    181      "TOT_LINE_UAR_PCT"   NUMBER(5,2) NOT NULL ENABLE,
    182      "SSN"                VARCHAR2(9 CHAR) NOT NULL ENABLE,
    183      "CHARGE_FROM_DT" DATE,
    184      "CHARGE_TO_DT" DATE,
    185      "SUBCUST_QUAL1"      VARCHAR2(15 CHAR) NOT NULL ENABLE,
    186      "SUBCUST_QUAL2"      VARCHAR2(15 CHAR) NOT NULL ENABLE,
    187      "REIMB_AGREEMENT"    VARCHAR2(25 CHAR) NOT NULL ENABLE,
    188      "TOT_DISCOUNT_AMT"   NUMBER(26,3) NOT NULL ENABLE,
    189      "TOT_SURCHARGE_AMT"  NUMBER(26,3) NOT NULL ENABLE,
    190      "ACCUMULATE"         VARCHAR2(1 CHAR) NOT NULL ENABLE,
    191      "VAT_TREATMENT_GRP"  VARCHAR2(4 CHAR) NOT NULL ENABLE,
    192      "COUNTRY_VAT_BILLFR" VARCHAR2(3 CHAR) NOT NULL ENABLE,
    193      "COUNTRY_VAT_BILLTO" VARCHAR2(3 CHAR) NOT NULL ENABLE,
    194      "VAT_TREATMENT"      VARCHAR2(4 CHAR) NOT NULL ENABLE,
    195      "PHYSICAL_NATURE"    VARCHAR2(1 CHAR) NOT NULL ENABLE,
    196      "COUNTRY_LOC_BUYER"  VARCHAR2(3 CHAR) NOT NULL ENABLE,
    197      "STATE_LOC_BUYER"    VARCHAR2(6 CHAR) NOT NULL ENABLE,
    198      "COUNTRY_LOC_SELLER" VARCHAR2(3 CHAR) NOT NULL ENABLE,
    199      "STATE_LOC_SELLER"   VARCHAR2(6 CHAR) NOT NULL ENABLE,
    200      "VAT_SVC_SUPPLY_FLG" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    201      "VAT_SERVICE_TYPE"   VARCHAR2(1 CHAR) NOT NULL ENABLE,
    202      "COUNTRY_VAT_PERFRM" VARCHAR2(3 CHAR) NOT NULL ENABLE,
    203      "STATE_VAT_PERFRM"   VARCHAR2(6 CHAR) NOT NULL ENABLE,
    204      "COUNTRY_VAT_SUPPLY" VARCHAR2(3 CHAR) NOT NULL ENABLE,
    205      "STATE_VAT_SUPPLY"   VARCHAR2(6 CHAR) NOT NULL ENABLE,
    206      "STATE_SHIP_FROM"    VARCHAR2(6 CHAR) NOT NULL ENABLE,
    207      "STATE_SHIP_TO"      VARCHAR2(6 CHAR) NOT NULL ENABLE,
    208      "MAST_CONTR_ID"      VARCHAR2(25 CHAR) NOT NULL ENABLE,
    209      "TAX_CUST_ID"        VARCHAR2(15 CHAR) NOT NULL ENABLE,
    210      "BUSINESS_UNIT_AM"   VARCHAR2(5 CHAR) NOT NULL ENABLE,
    211      "BUSINESS_UNIT_AMTO" VARCHAR2(5 CHAR) NOT NULL ENABLE,
    212      "ASSET_ID"           VARCHAR2(12 CHAR) NOT NULL ENABLE,
    213      "PROFILE_ID"         VARCHAR2(10 CHAR) NOT NULL ENABLE,
    214      "COST_TYPE"          VARCHAR2(1 CHAR) NOT NULL ENABLE,
    215      "STATE_VAT_DEFAULT"  VARCHAR2(6 CHAR) NOT NULL ENABLE,
    216      "SO_ID"              VARCHAR2(15 CHAR) NOT NULL ENABLE,
    217      "BUSINESS_UNIT_RF"   VARCHAR2(5 CHAR) NOT NULL ENABLE,
    218      "SOURCE_REF_TYPE"    VARCHAR2(3 CHAR) NOT NULL ENABLE,
    219      "SOURCE_REF_NO"      VARCHAR2(35 CHAR) NOT NULL ENABLE,
    220      "SOURCE_REF_KEY"     VARCHAR2(5 CHAR) NOT NULL ENABLE,
    221      "USER_AMT1"          NUMBER(26,3) NOT NULL ENABLE,
    222      "USER_AMT2"          NUMBER(26,3) NOT NULL ENABLE,
    223      "USER_DT1" DATE,
    224      "USER_DT2" DATE,
    225      "USER1" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    226      "USER2" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    227      "USER3" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    228      "USER4" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    229      "USER5" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    230      "USER6" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    231      "USER7" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    232      "USER8" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    233      "USER9" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    234      "SETID" VARCHAR2(5 CHAR) NOT NULL ENABLE,
    235      "ADD_DTTM" TIMESTAMP (6),
    236      "LAST_UPDATE_DTTM" TIMESTAMP (6),
    237      "DELETE_ROWS" VARCHAR2(1 CHAR) NOT NULL ENABLE,
    238      "BOOK"        VARCHAR2(10 CHAR) NOT NULL ENABLE,
    239      "DTTM_STAMP" TIMESTAMP (6),
    240      "VAT_RVRSE_CHG_GDS"  VARCHAR2(1 CHAR) NOT NULL ENABLE,
    241      "TAX_CD_VAT_RVC"     VARCHAR2(8 CHAR) NOT NULL ENABLE,
    242      "TAX_CD_VAT_RVC_PCT" NUMBER(7,4) NOT NULL ENABLE,
    243      "VAT_AMT_RVC"        NUMBER(26,3) NOT NULL ENABLE,
    244      "VAT_AMT_RVC_BSE"    NUMBER(26,3) NOT NULL ENABLE,
    245      "VAT_AMT"            NUMBER(26,3) NOT NULL ENABLE,
    246      "VAT_AMT_BSE"        NUMBER(26,3) NOT NULL ENABLE,
    247      "TAX_CD_VAT_PCT"     NUMBER(7,4) NOT NULL ENABLE
    248    )
    249    SEGMENT CREATION DEFERRED PCTFREE 10 PCTUSED 80 INITRANS 1 MAXTRANS 255 N
    OCOMPRESS LOGGING STORAGE
    250    (
    251      INITIAL 16384 NEXT 16384 MAXEXTENTS 2147483645 PCTINCREASE 0
    252    )
    253    TABLESPACE "AMAPP" ;
    
    Table created.
    
    Elapsed: 00:00:00.76
    SQL> CREATE UNIQUE INDEX "SYSADM"."DRIVERTEST1" ON "SYSADM"."DRIVERTEST"
      2    (
      3      "PROCESS_INSTANCE", "INTFC_ID", "INTFC_LINE_NUM", "TRANS_TYPE_BI", "TRA
    NS_TYPE_BI_SEQ"
      4    )
      5    PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
      6    (
      7      INITIAL 16384 NEXT 106496 MAXEXTENTS 2147483645 PCTINCREASE 0
      8    )
      9    TABLESPACE "PSINDEX" ;
    
    Index created.
    
    Elapsed: 00:00:00.04
    SQL>
    SQL> drop table DRIVERTEST;
    
    Table dropped.
    
    Elapsed: 00:00:24.90
    This is company Oracle 11.2.0.3 on 64-bit Windows.

    Thanks for any input.

    Mika wrote:
    >
    user as a result of the drop statement

    Let fall the waterfall DRIVERTEST table purge constraints;
    >

    Translates into a decline of almost immediate table, why is this? Does this mean that the longest execution time has been only because the table has been preserved in the trash?

    If correctly, I assume you're on Peoplesoft, you should try turn off the recyclebin before running the script generated by the application Designer, or purge the first recyclebin which could be huge because of the mechanism of migration of Peoplesoft.
    Or probably better, in the configuration settings, tab "Alter", check "Alter in place" instead of "Alter by changing the Table name". "." The first will modify the table, to create a temporary table (fill in the former), drop the old, then rename the temporary table.

    And don't forget to add crazy missing "when sqlerror exit" at the beginning of the script, otherwise you could have a very sad surprise.

    Nicolas.

    Comment added to configuration settings
    Published by: Gasparotto N on April 12, 2013 13:07

  • drop table conditionally for help where is?

    Hi all

    Not sure if I'm doing this right. My SQL is to identify the files that I want to delete properly, when I do manual QC, but I don't know how to delete records identified off the Table.

    The table I want to remove on a lot of columns, but when a condition is fulfilled on the 2 posts I'm looking on, I want to delete the rest of the columns, regardless of what they are.

    When the combination of the two columns CUST_ID and MIN (STAMP_DATE) exists, then delete this line, or maybe I'm not quite do this right. Basically, there are 2 lines (duplicate for each cust_id) and I want to delete lines with the oldest Date, that's why I use MIN (DATE) Date_field and keep the Max (Date) for the remaining fields.

    Thanks for help in advance.
    DELETE FROM Table_A
    WHERE EXISTS
    
    (
     
    SELECT CUST_ID, MIN(STAMP_DATE) as MIN_DATE
    FROM
    (
    
    SELECT CUST_ID, STAMP_DATE
    FROM 
    (
        SELECT T1.*, COUNT(*) OVER ( PARTITION BY CUST_ID ) X
        FROM Table_A T1
        WHERE SALES_PERSON is null
    )
    WHERE X > 1
    
    ORDER BY CUST_ID)
    Group by CUST_ID
    );

    Hello

    Whenever you have a problem, please post a small example of data (CREATE TABLE and only relevant columns, INSERT statements) of all the tables.
    Also post the results you want from this data, as well as an explanation of how you get these results from these data, with specific examples.
    If you ask on a DML, such as DELETE statement, CREATE TABLE and INSERT statements need to re - create the tables as they are before the DML, and results will be the content of the or the tables changed when it's all over.
    Always tell what version of Oracle you are using.

    Kodiak_Seattle wrote:
    Hi all

    Not sure if I'm doing this right. My SQL is to identify the files that I want to delete properly, when I do manual QC, but I don't know how to delete records identified off the Table.

    If you have a query that displays correctly the lines you want to REMOVE? The request message. If it is worth mentioning at all, display it.

    The table I want to remove on a lot of columns, but when a condition is fulfilled on the 2 posts I'm looking on, I want to delete the rest of the columns, regardless of what they are.

    DELETE means delete a row in a table. All rows have the same number of columns. There is no way to delete only some columns in a row. You can delete the entire line. Changing values on an existing line is called update, do not REMOVE, even if you are chaning the columns to NULL.
    You can, however, some of the columns set to NULL and leaving the other intact columns. Is that what you want? It would really help if you posted an example.

    When the combination of the two columns CUST_ID and MIN (STAMP_DATE) exists, then delete this line, or maybe I'm not quite do this right. Basically, there are 2 lines (duplicate for each cust_id) and I want to delete lines with the oldest Date, that's why I use MIN (DATE) Date_field and keep the Max (Date) for the remaining fields.

    When you say 'field', do you mean "column?
    What do you mean by "keep the Max (Date) for the rest fields? Are you talking about an UPDATE? All other dates columns, and you want to make all equal to stamp_date? It would really help if you posted an example.

    Thanks for help in advance.

    DELETE FROM Table_A
    WHERE EXISTS
    
    (
    
    SELECT CUST_ID, MIN(STAMP_DATE) as MIN_DATE
    FROM
    (
    
    SELECT CUST_ID, STAMP_DATE
    FROM
    (
    SELECT T1.*, COUNT(*) OVER ( PARTITION BY CUST_ID ) X
    FROM Table_A T1
    WHERE SALES_PERSON is null
    )
    WHERE X > 1
    
    ORDER BY CUST_ID)
    Group by CUST_ID
    );
    

    I think what you want is:

    DELETE FROM table_a
    WHERE   (cust_id, stamp_date)     IN ( SELECT  cust_id
                                       ,       MIN (stamp_date)
                               FROM    table_a
                             )
    ;
    

    This assumes that the combination (cust_id, stamp_date) is unique. If it is not (for example, if you have 2 or more lines for the same cust_id, and all have the same exact stamp_date), then you need something a little more complicated.

  • A SQL better to avoid increases in the index

    Our developer past this code along with us as we receive some performance and behavior in our DB 9.2.0.7. Using this process, our 4 MB index rises to more than 1.5 GB and we are forced to re - org to bring him down.
    BEGIN
    PRETERR := 'NO ERROR';
    PRETCODE := 0;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectalias';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectalias', V.PVR_ALIAS, NULL, NULL
    FROM T_PARTY_VERSION V, T_PARTY PT, T_PARTY_FUNCTION F
    WHERE PT.PTY_PARTY_ID = V.PVR_PTY_PARTY_ID
    AND F.PFY_PTY_PARTY_ID = PT.PTY_PARTY_ID
    AND SYSDATE BETWEEN PVR_EFFECTIVE_START_DATE AND
    PVR_EFFECTIVE_END_DATE
    AND PT.PTY_PARTY_STATUS <> 'D'
    AND V.PVR_ALIAS IS NOT NULL
    AND F.PFY_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectlender';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectlender', V.PVR_BUSINESS_NAME, NULL, NULL
    FROM T_PARTY_VERSION V, T_PARTY PT, T_PARTY_FUNCTION F
    WHERE PT.PTY_PARTY_ID = V.PVR_PTY_PARTY_ID
    AND F.PFY_PTY_PARTY_ID = PT.PTY_PARTY_ID
    AND SYSDATE BETWEEN PVR_EFFECTIVE_START_DATE AND
    PVR_EFFECTIVE_END_DATE
    AND PT.PTY_PARTY_STATUS <> 'D'
    AND V.PVR_BUSINESS_NAME IS NOT NULL
    AND F.PFY_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectlendername';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectlendername', PP.PRP_COLUMN_1, NULL, NULL
    FROM T_POLICY, T_POLICY_PARTY, T_POLICY_PARTY_PROPERTY PP
    WHERE POL_POLICY_ID = PPA_POL_POLICY_ID
    AND PPA_EFFECTIVE_END_DATE = TO_DATE('9999-01-01', 'RRRR-MM-DD')
    AND PPA_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    AND POL_POLICY_ID = PP.PRP_POL_POLICY_ID
    AND PP.PRP_EFFECTIVE_END_DATE = TO_DATE('9999-01-01', 'RRRR-MM-DD')
    AND PP.PRP_COLUMN_1 IS NOT NULL
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectinsinstcode';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectinsinstcode', V.PVR_INSTITUTION_CODE, NULL, NULL
    FROM T_PARTY_VERSION V, T_PARTY PT, T_PARTY_FUNCTION F
    WHERE PT.PTY_PARTY_ID = V.PVR_PTY_PARTY_ID
    AND F.PFY_PTY_PARTY_ID = PT.PTY_PARTY_ID
    AND SYSDATE BETWEEN PVR_EFFECTIVE_START_DATE AND
    PVR_EFFECTIVE_END_DATE
    AND PT.PTY_PARTY_STATUS <> 'D'
    AND V.PVR_INSTITUTION_CODE IS NOT NULL
    AND F.PFY_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectinstransit';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectinstransit', V.PVR_TRANSIT_NUM, NULL, NULL
    FROM T_PARTY_VERSION V, T_PARTY PT, T_PARTY_FUNCTION F
    WHERE PT.PTY_PARTY_ID = V.PVR_PTY_PARTY_ID
    AND F.PFY_PTY_PARTY_ID = PT.PTY_PARTY_ID
    AND SYSDATE BETWEEN PVR_EFFECTIVE_START_DATE AND
    PVR_EFFECTIVE_END_DATE
    AND PT.PTY_PARTY_STATUS <> 'D'
    AND V.PVR_TRANSIT_NUM IS NOT NULL
    AND F.PFY_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectSubInstCode';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectSubInstCode', V.PVR_INSTITUTION_CODE, NULL, NULL
    FROM T_PARTY_VERSION V, T_PARTY PT, T_PARTY_FUNCTION F
    WHERE PT.PTY_PARTY_ID = V.PVR_PTY_PARTY_ID
    AND F.PFY_PTY_PARTY_ID = PT.PTY_PARTY_ID
    AND SYSDATE BETWEEN PVR_EFFECTIVE_START_DATE AND
    PVR_EFFECTIVE_END_DATE
    AND PT.PTY_PARTY_STATUS <> 'D'
    AND V.PVR_INSTITUTION_CODE IS NOT NULL
    AND F.PFY_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectSubTransNum';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectSubTransNum', V.PVR_TRANSIT_NUM, NULL, NULL
    FROM T_PARTY_VERSION V, T_PARTY PT, T_PARTY_FUNCTION F
    WHERE PT.PTY_PARTY_ID = V.PVR_PTY_PARTY_ID
    AND F.PFY_PTY_PARTY_ID = PT.PTY_PARTY_ID
    AND SYSDATE BETWEEN PVR_EFFECTIVE_START_DATE AND
    PVR_EFFECTIVE_END_DATE
    AND PT.PTY_PARTY_STATUS <> 'D'
    AND V.PVR_TRANSIT_NUM IS NOT NULL
    AND F.PFY_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectFileOwner';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectFileOwner',
    PVR_FIRST_NAME || ' ' ||
    DECODE(PVR_MIDDLE_NAME,
    NULL,
    '',
    PVR_MIDDLE_NAME || ' ') || PVR_LAST_NAME,
    NULL,
    PTY_PARTY_CODE
    FROM T_ROLE TR, T_USER_ROLE TUR, T_PARTY TP, T_PARTY_VERSION TPV
    WHERE TP.PTY_PARTY_ID = TPV.PVR_PTY_PARTY_ID
    AND SYSDATE BETWEEN TPV.PVR_EFFECTIVE_START_DATE AND
    TPV.PVR_EFFECTIVE_END_DATE
    AND TP.PTY_PARTY_ID = TUR.ULE_PFY_PTY_PARTY_ID
    AND (SYSDATE BETWEEN TUR.ULE_START_DATE AND TUR.ULE_END_DATE OR
    TUR.ULE_END_DATE IS NULL)
    AND TR.RLE_ROLE_ID = TUR.ULE_RLE_ROLE_ID
    AND PTY_PARTY_CODE NOT LIKE 'LTEST%'
    AND TR.RLE_ROLE_NAME IN
    ('VPOPS', /*'VPRSK2', */
    'OPSLEADER', 'TEAMLEADER', 'OPSLEVEL5', 'OPSLEVEL4', 'OPSLEVEL3',
    'OPSLEVEL2', 'OPSLEVEL1', 'OPSTRNG')
    AND PTY_PARTY_CODE IS NOT NULL
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectbrokername';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectbrokername', PP.PPA_NAME_BROKER_TEXT, NULL, NULL
    FROM T_POLICY, T_POLICY_PARTY PP
    WHERE POL_POLICY_ID = PPA_POL_POLICY_ID
    AND PPA_EFFECTIVE_END_DATE = TO_DATE('9999-01-01', 'RRRR-MM-DD')
    AND PPA_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    AND TRIM(PP.PPA_NAME_BROKER_TEXT) IS NOT NULL 
    ORDER BY 2;
    
    DELETE FROM T_TEAM_LIST_VAL WHERE LIST_DOMAIN = 'selectorg';
    INSERT INTO T_TEAM_LIST_VAL
    (LIST_DOMAIN, LIST_VALUE_1, LIST_VALUE_2, LIST_VALUE_3)
    SELECT DISTINCT 'selectorg', PT.PTY_PARTY_CODE, NULL, NULL
    FROM T_PARTY_VERSION V, T_PARTY PT, T_PARTY_FUNCTION F
    WHERE PT.PTY_PARTY_ID = V.PVR_PTY_PARTY_ID
    AND F.PFY_PTY_PARTY_ID = PT.PTY_PARTY_ID
    AND SYSDATE BETWEEN PVR_EFFECTIVE_START_DATE AND
    PVR_EFFECTIVE_END_DATE
    AND PT.PTY_PARTY_STATUS <> 'D'
    AND PT.PTY_PARTY_CODE IS NOT NULL
    AND F.PFY_SHR_STAKE_HOLDER_FN_CODE = 'LENDER'
    ORDER BY 2;
    COMMIT;
    1 it is with a delete and insert one after another, it will grow quickly? Would it not be better to perform all delete them first, validation and then inserts and commit?

    Question 2 is at a high level, what method would be better. We have much that truncation, however, the developer only deletes the data of 40%.

    huh? wrote:
    Our developer past this code along with us as we receive some performance and behavior in our DB 9.2.0.7. Using this process, our 4 MB index rises to more than 1.5 GB and we are forced to re - org to bring him down.

    Your table definition shows the column indexed to TANK (200) - which means the length fixed; up to 4MB is equivalent to 20,000 lines. If it grows to 1.5 GB and rebuilt to 4 MB at one point your index finger running then to about 80 KB per index entry. If, as you describe, you only remove about 40 percent of the data and re - insert a similar amount that once the you must have hit a bug.

    You're on 9.2.0.7 (buggy) - were you using SAMS (also buggy). I came across a bug with the SAMS once that gave rise to a process using only 3 blocks from each measure in the index that it is returned in a pl/sql loop to change a few hundred lines. Different circumstances of yours and an earlier version - but you can beat something similar.

    A few thoughts:


      If it's in the SAMS move the indexes of a tablespace managed by freelist to see what is happening
      If you need index could make you it unusable for the load
      If you have the index at all?
      This table would be partitioned list on listdomain - you can then use Exchange partition to load the data like this

    Commit between delete and insert allows generally in such cases.
    Between each pair of delete/insert (in the absence of bugs) should help

    Concerning
    Jonathan Lewis.

  • Necessary insight as to how the Stats are cascaded to the index after updates.

    SCENARIO OF

    • We have a process of intensive loading (100 s of the tables involved, several hours of execution). We collect stats diagram only on obsolete objects when executing to minimize the load on the system while the statistics come together at intervals (see the command below).

    • There is a table with an index on column X
    • When the table is inserted in during a charge process column X is null and that the index is empty.
    • When the table becomes stale (and the column X is null of remains), his stats get generated using the package gather_schema_stats with the STALE 'COLLECT' and ' CASCADE = TRUE options.

    • Subsequently, all records from the table are loaded and the collection of statistics has occurred, column X happens to updated with the values so then inserted in the index. More no record is inserted into the table.


    QUESTION

    After the charge fit more no record and the table never gets denial as defective if new stats are not generated (no surprise). However, what is the impact on the index which now has lines in there (as a result of updates that occurred after the loading table has been loaded)? When the stats were executed on the table (with case sensitive = true) index was empty. Do I need a work of gather_stats separated on the index or somehow, it will inherit the values associated with the full table optimizer statistics? _

    Here is the command I use:
    exec dbms_stats.gather_schema_stats (ownname = > 'UICONNECT',-)
    Options = > "FADE TOGETHER",
    estimate_percent = > dbms_stats.auto_sample_size, -.
    method_opt = > 'for all columns size auto ' -.
    degree = > dbms_stats.auto_degree;
    Cascade = > TRUE);

    This problem is forcing me to understand the optimizer (viz has know statistics) more than I hoped would be necessary. But alas... developers ask me if I need to manage (correctly)!

    Thanks in advance for any idea on this issue (or references to good material... it's hard to google it).

    Published by: TonyG on July 14, 2010 14:10

    Published by: TonyG on July 14, 2010 14:11

    Just to clarify one thing:
    "Cascade" not "copy" table to the indices statistics.
    Cascade just make sure that you don't have to hard-code calls individual gather_index_stats. So this means that its index stats are also gathered, based on what is in the index.
    This means that the generated statistics will be inaccurate, once the column is filled, as probably the key indicator, the clustering_factor, of the index will change.
    So yes, his stats should be re-assembled, or you can decide (when the grouping after load factor is relatively constant) to block these statistics and to exclude the gathering.

    HTH
    -------------
    Sybrand Bakker
    Senior Oracle DBA

  • How to increment the index of row/column in multi-column listbox

    Hello

    I developed a program in which the multicolumn list box values are read and forwarded to another mechanism. To read specific values in the list box, I used index table to retrieve the value of a particular cell to the instrument.

    Allows, for example if I want to run the VI several times and I want to increment the line index whenever the tracks VI as well as for successive runs, the values of the next level of lines are read.

    For example. I have the following listbox

    HAD Vd Vg

    1 0.3 0.2

    2 0.4 0.6

    So for the first round, based on the index which I note the listbox can read 0.2 and 0.3 and assume that if I run this VI for lets say 2 times during the 2nd time it should read 0.4 and 0.6 instead of 0.2 and 0.3.Is it is it possible to increment the line/column index automatically? Please help me because this is the last step of my project.

    Thank you

    Robin

    Your VI runs millions of times per second and elements within nanoseconds. You need to prevent this.

    Here is a quick modification that goes to the next line, every time that you run the VI again and again when he's run out of items.

    It might give you some ideas...

  • The index on the field date

    Please see my table
    create table DATE_TEST
    (
      ID         VARCHAR2(6) not null,
      ID_DESC    VARCHAR2(250),
      START_DATE DATE,
      END_DATE   DATE
    );
    -- Create/Recreate primary, unique and foreign key constraints 
    alter table DATE_TEST
      add constraint DATE_TEST_PK primary key (ID);
    -- Create/Recreate indexes 
    create index DATE_TEST_IDX1 on DATE_TEST (END_DATE));
    create index DATE_TEST_IDX2 on DATE_TEST (START_DATE);
    No I haven't added some data in the table. My problem is that it does not index between the query.

     EXPLAIN PLAN FOR SELECT * FROM       DATE_TEST WHERE           start_date between to_date('01/01/2012','DD/MM/YYYY') AND to_date('31/12/2012','DD/MM/YYYY')           OR  end_date between to_date('01/01/2012','DD/MM/YYYY') AND to_date('31/12/2012','DD/MM/YYYY')
      2  /
    
    Explained
    
    SQL>      SELECT * FROM  TABLE( DBMS_XPLAN.display);
    
    PLAN_TABLE_OUTPUT
    --------------------------------------------------------------------------------
    Plan hash value: 4189439861
    -------------------------------------------------------------------------------
    | Id  | Operation         | Name      | Rows  | Bytes | Cost (%CPU)| Time     |
    -------------------------------------------------------------------------------
    |   0 | SELECT STATEMENT  |           |   954 |   139K|     7   (0)| 00:00:01 |
    |*  1 |  TABLE ACCESS FULL| DATE_TEST |   954 |   139K|     7   (0)| 00:00:01 |
    -------------------------------------------------------------------------------
    Predicate Information (identified by operation id):
    ---------------------------------------------------
       1 - filter("START_DATE">=TO_DATE(' 2012-01-01 00:00:00',
                  'syyyy-mm-dd hh24:mi:ss') AND "START_DATE"<=TO_DATE(' 2012-12-31
                  00:00:00', 'syyyy-mm-dd hh24:mi:ss') OR "END_DATE">=TO_DATE('
                  2012-01-01 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND
                  "END_DATE"<=TO_DATE(' 2012-12-31 00:00:00', 'syyyy-mm-dd hh24:mi:s
    Note
    -----
    
    PLAN_TABLE_OUTPUT
    --------------------------------------------------------------------------------
       - dynamic sampling used for this statement (level=2)
    
    21 rows selected
    Why it does not index and what are the other solutions for this

    Your query does not take the index because the cost of FTS is lower than that of the index analysis...

    You could put a TIP if you want to force the use of the index - which is NOT ADVISED.

  • Help! Get the index of the character in the Characters collection

    for example, in a script I have to as fast and delete the text from the beginning of the paragraph charater until the first tab (or dot or colon or 'something'), as simple as posible.

    I was expecting something like

    myText=myParagraph.characters.itemByRange(0,"\t");
    myText.remove();
    

    Of course I can use grep, but it has its problems, and I was hoping that I don't have to (especialy because the script will need to do to 400 + times.)

    Any help?

    Vamitul

    I don't know if this is the way which go to this topic, but this is what you are looking for.

    myParagraph=app.selection[0].paragraphs[0];
    myText=myParagraph.characters.itemByRange(0,myParagraph.contents.toString().indexOf("\t"));
    myText.remove();
    

    (("To remove until the tab not including it use myText=myParagraph.characters.itemByRange(0,myParagraph.contents.toString().indexOf("\t ")-1);

    Trevor

    Post edited by: ~ Trevor ~.

  • Dropped tables of user account appears not not in the recyclebin

    I found another thread with a similar problem, but from a sys account, but this isn't the case for me. For starters I have a student just learning Oracle so have the limits of knowledge.
    First, I installed Oracle Express 11 on XP in a virtual machine. I use SQL developer to access. I created a user with my name and allocated a similar name tablespace.

    CREATE TABLE PROVINCE_ID (ID NUMBER (10), VARCHAR2 (30)) OF THE PROVINCE;
    DROP TABLE PROVINCE_ID;
    FLASHBACK TABLE PROVINCE_ID FROM BEFORE THE FALL.

    The create and drop work fine, but the return of flame fails because of "no such table in the recyclebin" this is confirmed by selecting the trash and verification.
    Due to some further research, I tried:

    See THE recyclebin parameter;

    and confirmed the value is ONE

    Also using a
    See THE recyclebin;
    nets no results as expected because nothing is in it.

    Now I try one
    ALTER SESSION recyclebin = ON; (This command Alter system version fails)
    just to make sure it's on no effect.

    Any ideas on why the recyclebin is not grabbing my deleted tables?

    Edited by: 914271 February 13, 2012 21:11

    Flashback is not supported and is disabled on XE.

    Check the availability of a feature table 1-1 for editions of Oracle database

    in the doc of the licenses of database information

    http://docs.Oracle.com/CD/B28359_01/license.111/b28287/editions.htm

  • Is it possible to create interactive drop-down lists that reference the tables on pages separate from the PDF?

    I'm looking to create a user to input PDF in the drop-down lists are used to search for tables, however, I'm not very familiar with the options that are available or if this is even possible?  Also, is it possible to write a substantive code that could read the text of the user entered to perform a search or even solve an equation? Can someone let me know if these elements are possible and/or let me know what adobe program may be required to accomplish these tasks? Thank you!

    PDF documents have no concept of "tables" as MS Word or MS Excel has. There is content that looks like a table.

    Acrobat JavaScript knows tables and form fields. So we could have a table in JavaScript and complete a series of fields that looks like a table. You can use JavaScript to find the table.

    JavaScript in Acrobat can accept user entries in the fields and pop-up windows.

    It is possible to solve theoretical equations the user if the good rating or coding is used.

    D.P. Story is an evangelist generated LaTex PDF to create PDFS with mathematical symbols, and he also created the AcroTex product that allows to create educational tools that includes mathematics calculation self placement tests.

  • Dropped table not in the Recycle Bin

    Hi all

    I dropped a table, and was not in the basket while my recycle bin is enabled and the size is 50 M. Take a look below.

    SQL > show parameter recycle

    VALUE OF TYPE NAME
    ------------------------------------ ----------- ------------------------------
    buffer_pool_recycle string
    db_recycle_cache_size big around 52 M
    Recyclebin string on
    SQL > select * from students;

    ID NAME MY
    -- ---------- --
    1 Max 20
    2 John 30
    3 ram 34

    SQL > select * from recyclebin
    2;

    no selected line

    SQL > drop table students;

    Deleted table.

    SQL > select * from recyclebin.

    no selected line

    SQL > select * from students;
    Select * from students
    *
    ERROR on line 1:
    ORA-00942: table or view does not exist


    SQL > restoration
    2
    SQL >;
    1 * restore
    SQL > rollback;

    Complete restoration.

    SQL > select * from students;
    Select * from students
    *
    ERROR on line 1:
    ORA-00942: table or view does not exist


    SQL > flashback table students before drop;
    table students Flashback to before the fall
    *
    ERROR on line 1:
    ORA-38305: object not in the Recycle BIN

    read the thread below:
    Why the table not deleted in recyclebin?

    Answer is there.

  • Trigger system Oracle fired twice on the drop table

    Hi all

    I'm using the Oracle 11 g on windows server 2003 R2 standard edition service pack 2. I am creating a trigger in a scheme called 'stock' by logging in as the owner of the schema. Here is my code for the same thing:
     create or replace TRIGGER AUDIT_SYS_TR_TEST
       AFTER  ALTER OR DROP ON DATABASE
      BEGIN
        IF(ora_sysevent = 'DROP' AND UPPER(ora_login_user) not in ('SYS','SYSTEM')) THEN
         DBMS_OUTPUT.PUT_LINE(ora_sysevent);
        ELSIF(ora_sysevent = 'ALTER' AND UPPER(ora_login_user) not in ('SYS','SYSTEM')) THEN
         DBMS_OUTPUT.PUT_LINE(ora_sysevent);
        END IF;
      END; 
    The goal is to activate whenever change or fall occurs on a database object (IE any object database). So I created a table called trigtest like this in the same schema as the trigger:

    CREATE TABLE TRIGTEST(COL1 VARCHAR(20));
    Then I tried to drop the table:
    DROP TABLE TRIGTEST;
    That's what I got as serveroutput after the drop statement:

    ALTER
    DROP

    Can someone please shed some light as to why the events the alter and drop are being triggered when only the drop statement is called?

    894302 wrote:
    I activated recyclebin... same problem exists...

    Yep, that's precisely the 'problem '... Check the test script I posted.

    If the recyclebin is enabled as part of the move action, Oracle renames the table to a system generated name.

    Use the drop-DOWN list with PURGE option if you want to:

    SQL> DROP TABLE TRIGTEST purge;
    DROP TABLE TRIGTEST purge
    DROP
    
    Table dropped.
    

    Edited by: odie_63 nov 1. 2011 19:36

  • Drop table for a user, where the table has special characters.

    I have to delete tables starting with BIN. How can I do? This is Oracle database 11g.

    SQL > select * from tab;

    TNOM TABTYPE CLUSTERID
    ------------------------------ ------- ----------
    BIN$ 7J51dMFbQ36/jjLPLdzXeg == $0 TABLE
    BIN$ CaCh7QhdRDqlyJo9JETBaA == $0 TABLE
    BIN$ J + 4ibk96QZ + PZCDGGNx8Tw == $0 TABLE
    BIN$ NvnXFcd4QBW4uYMqOu8H6A == $0 TABLE
    BIN$ RaCaPOaTSXyKDlZZG2ua7Q == $0 TABLE
    BIN$ aGKXrnwlQRe + e0IH6tEBPQ == $0 TABLE
    BIN$ fA5I + 2xsQy66mF7koOoYkA == $0 TABLE
    BIN$ lLxLZF3BQ0eum9Ia4rtqYA == $0 TABLE
    BIN$ nKZ5hquHRRWHa9daNsa5XQ == $0 TABLE
    BONUS BOARD
    DEPT TABLE

    TNOM TABTYPE CLUSTERID
    ------------------------------ ------- ----------
    EMP TABLE
    SALGRADE TABLE

    13 selected lines.

    I tried to drop one of them and it gave an error saying that table_name is a special character;

    SQL > drop table BIN$ nKZ5hquHRRWHa9daNsa5XQ == $0;
    drop table BIN$ nKZ5hquHRRWHa9daNsa5XQ == $0
    *
    ERROR on line 1:
    ORA-00933: SQL not correctly completed command.


    Please suggest. Thanks in advance.

    10 g recyclebin default is on, and whenever there is drop table statement it goes to recyclebin. To avoid this fall of the table must be with the keyword to purge as,.
    SQL > drop table t is serving;
    Otherwise, you can change db setting to turn off recyclebin and the object will not go to recyclebin after that. See http://www.orafaq.com/forum/t/72161/2/

    Kind regards
    Julien

  • See the recyclebin not shown anything once drop table

    currently test flashback table, but I wonder why recycle bin does not show anything after release? I check the parameter and the value is enabled. now it has me thinking there at - it a link between re-use locker, retention of undo and undo SCT size?

    If so why it does not work on a undo_retention = 900, cancellation of TBS size = 100MB and the table that I dropped consisting of 1 single column and type of 3 lines data number, which is particularly small. is there something that I need to put more?

    DB version is 10.2.0.1.0

    Thank you!

    mitchykoi wrote:
    It is also possible that all SYS objects can be stored or seen in a recyclebin?

    Only if the user Sys is store in a tablespace nonsystem as below,

    SQL> conn / as sysdba
    Connected.
    SQL> create table test_rbin2(a char) tablespace users;
    
    Table created.
    
    SQL> select table_name, tablespace_name
      2  from user_tables where table_name='TEST_RBIN2';
    
    TABLE_NAME                     TABLESPACE_NAME
    ------------------------------ ------------------------------
    TEST_RBIN2                     USERS
    
    SQL> show recyclebin
    SQL> drop table test_rbin2
      2  ;
    
    Table dropped.
    
    SQL> show recyclebin
    ORIGINAL NAME    RECYCLEBIN NAME                OBJECT TYPE  DROP TIME
    ---------------- ------------------------------ ------------ -------------------TEST_RBIN2       BIN$l/0nppCwhObgQL4KFEMjfA==$0 TABLE        2010-12-22:09:12:39SQL>
    

    You can see that the table is now in the recyclbin. Its actually the tablespace that would govern this thing. System tablespace is special and its objects are special treaties as well. The Sys user is supposed to be the owner of the system default tablespace (it's too) so by default, any drop table made here would not go to recyclebin.

    as a recyclebin for system objects only?

    No, there is no such thing.

    Also, what are the importance of the following: buffer_pool_recycle, db_recycle_cache_size for the garbage?

    Db_recycle_cache_size actually has Nothing to do with the Recyclebin except that it shares a common word with the latest. Buffer_pool_recycle also has nothing to do with the Recyclebin and actually, it has nothing to do at all of 10.1, because it is an obsolete parameter and is replaced by, guess what, db_recycle_cache_size .

    HTH
    Aman...

Maybe you are looking for

  • Accidents of software DVD Toshiba Qosmio Player X 300-12 H

    Since then, I have buy havn't been able to use from Toshiba DVD player software.I had the laptop for 2 months and just after Christmas, I realized that I had not tried the Toshiba DVD software because I used the player of Windows Entertainment Center

  • DVCProHD to HDCAM uncompressed?

    We finished our edit here in the remote and mountainous desert Montana forest. I bring to Adobe first Pro XML in my 7.0.3 FCP timeline. So far so good. We have published with proxy files that had been captured in DVCPRO HD. For the level of quality t

  • How can I prevent the Oblivion crashes on windows 7?

    Oblivion crashes when I get to the point where the program enter the city.  How can I get Windows 7 Starter not to plant on this game?

  • 120 envy: envy of 120 - will not scan / photo copy

    Hello When I put the page I want to scan / photocopy to the screen (yes I put it the right way), print out shaded black.  The scanner moves on the screen, but the 'light' scanner doesn't work, then it is not bright enough or have enough light to read

  • Switch all 6500 FWSM

    I'm setting up a cisco 6509 switch with FWSM, but it a little confusing to implement. I'm following the next of the http://www.cisco.com/en/US/products/hw/modules/ps2706/products_configuration_example09186a00808b4d9f.shtmldocumentation, however, depe