0
votes
0answers
14 views

TEMP Tablespace Exceeded when DBMS_REDIFINITION

Oracle Environment. Table size is 500Gb. Free space left on hard drive - 300Gb. TEMP Tablespace is currently 20GB Task: do the DBMS_Redefinition for the table (partition by month) and optimize ...
0
votes
1answer
12 views

Oracle Text CTXCAT Domain Index, Transactional, and Before Insert/Update Trigger

TLDR: The CTXCAT index is supposed to be transactional, but Before Insert triggers that modify the indexed column don't seem to induce an update. I'm running on Oracle 9i. (Actually, I'm running on ...
1
vote
1answer
58 views

How to get index last modified time in Oracle?

Given an index name, I want to obtain its last modification time and the author of modification in Oracle 11g. Is there any query to achieve this?
1
vote
1answer
114 views

Why is this second query more expensive than the first?

While reading Graph Databases book, I came across this excerpt: I can't figure out why the second query is more expensive than the first. Indeed, both filter on the Bob person. May anyone ...
-1
votes
3answers
85 views

Full table scan even after adding index

i have two tables in Oracle 11g server one is partitioned and another is having a 3GB of data. I've added a composite index on both the tables based on the where clause, in the order it appears. The ...
1
vote
3answers
354 views

What's the most efficient UUID column type

For storing a 128 bits UUID there are multiple storage options: a byte[16] column two bigint/long(64 bits) columns a CHAR(36) column - 32 hex digits + 4 dashes. a UUID database specific column, if ...
0
votes
1answer
81 views

Tablespace of an index organized table

I want to find the tablespace of an index organized table with primary key. With dba_segments I can only find the tablespace for the primary key. But how can I find the tablespace for the table?
2
votes
0answers
134 views

Do OR conditions in Oracle SQL queries spoil index use / cause full table scan?

I have a query on Oracle 11g of the following type, which results in a series of highly inefficient full table scans: select t.Id, t.ObjectId, t...[other Tasks columns] , od1...[ObjectData1 ...
0
votes
3answers
55 views

Invalid create index syntax

I cannot create index with the where clause. Refer the below query: CREATE INDEX c_bplocation_isdefault ON c_bpartner_location (ad_client_id,c_bpartner_id,isdefault) WHERE isdefault = 'Y';
2
votes
2answers
211 views

DISTINCT not using an index [duplicate]

I have table (2139868 rows): COLUMN1 NUMBER(20,0) COLUMN2 XMLTYPE COLUMN3 XMLTYPE COLUMN4 VARCHAR2(50 BYTE) COLUMN5 VARCHAR2(50 BYTE) COLUMN6 VARCHAR2(50 BYTE) COLUMN7 VARCHAR2(50 BYTE) COLUMN8 ...
3
votes
0answers
90 views

Why would function based indices I’ve created lower the cost but now show up in the explain plan breakdown?

Sorry for the terrible column/table names but since this is for a work project I wanted to insure it was ok to ask. I was just hoping to at least learn why I'm not seeing my functional indices being ...
0
votes
0answers
150 views

index usages on table with recursive relationship

we are working on a project that uses jpa and oracle. In this project we have a table with a recursive relation: Create table alarm ( id varchar2(200), ... alarmcode varchar2(50), parent_id ...
1
vote
2answers
63 views

index for OR operator with different columns

What would be best index for this kind of query: -- id is the PK create table test3(id number,name varchar2(30) not null,lastname varchar2(30) not null); select id from test3 where id=:1 and ...
1
vote
1answer
400 views

Retrieve Data faster from a huge Oracle Table

I have a huge Oracle table ( ttdinv700 ) which contains almost 20 million rows. I am trying to execute the below query, on the table: select max(ttdinv700.t$trdt) from ttdinv700, ttiitm001 ...
0
votes
2answers
265 views

Unusable index on PK - Oracle DBMS

We are executing a large number of INSERT operations (140k circa) on a table during an ETL process and this error pops out: Caught SQLException for insert into DMALM_USER_ROLES [...] Caused by: ...
3
votes
1answer
87 views

How many blocks is my database

How can I write a query using Oracle SQL Developer to find how many blocks my database is using? (tables & indexes)
0
votes
1answer
83 views

Index being ignored by Oracle

I have a table for sensor data, simplified it looks like this: DEVICE_ID NUMBER SENSOR_ID NUMBER DATA_TIME NUMBER DATA_VALUE1 NUMBER The table constains billions of rows and is partitioned by week ...
0
votes
1answer
107 views

Oracle 11g INDEX_SS Hint

Given a table with columns A, B, and C of type CHAR(15) and an unique index If I have a query with a WHERE clause specifying A and C, oracle's optimizer chooses to do an index range scan. But if I ...
2
votes
4answers
1k views

How to find index organized table

I'm working on Oracle 11g database and I need to list all index-organized tables. Is there a dba's view to query for that ? Thanks
1
vote
2answers
4k views

What is difference between primary index, secondary index, unique index and normal index?

I work on Oracle systems where I two type of indices exists in any table: Unique index (Based on any search key which is unique key). Normal index (Index made on any search key which is not ...
1
vote
1answer
499 views

How to partition an Oracle table with 65 million rows?

The table that needs partitioning contains a list of Components and their Values. So one table is tblComponents. Another is tblFields. Then this table, tblValues, contains the values of the ...
1
vote
2answers
4k views

Index for date column for range query in Oracle?

We have a lot: select count(*) from TBL where XDATE between ? and ? and FLD = ?; We expect to boost performance by tuning index on XDATE column (which have DATE type). What type of indexes more ...
1
vote
1answer
461 views

Partitioning vs Indexes

I'm very new to databases, so I apologize if my question is very basic... Anyways, I'm creating a table with what seems like alot of data (500 million rows right now, and potentially twice as much in ...
1
vote
5answers
2k views

What happens when we create index

What happens exactly when I create an index on the empid column of this employee table CREATE TABLE employee ( empid number(5), ename varchar2(30), sal number(10,2) ); Let's assume the ...
3
votes
1answer
507 views

Index on foreign key makes query extremely slow

We are recently experiencing a tremendous query slowdown with spilled over temp tablespace. A specific query causes this problem. The queried table (table3) has an indexed PK, three FK with indexes ...
1
vote
0answers
60 views

Oracle - Mysterious indexes

I have a table in Oracle 10.2g that I'm trying to import roughly 11 million rows into. The table contains an SDO_GEOMETRY column. It previously had NOT NULL constraints on all 3 columns, a primary key ...
2
votes
1answer
295 views

Longest prefix search in Oracle

I have a list of phone number prefixes defined for large number of zones (in query defined by gvcode and cgi). I need to efficiently find a longest prefix that matches given number PHONE_NR. I use ...
1
vote
2answers
2k views

How do you correct a corrupted index in Oracle?

I have this ORA error in our logs: Caused by: java.sql.BatchUpdateException: ORA-01578: ORACLE data block corrupted (file # 8, block # 22921) ORA-01110: data file 8: ...
0
votes
1answer
146 views

How do you correct a corrupted index in Oracle? [duplicate]

I have this ORA error in our logs: Caused by: java.sql.BatchUpdateException: ORA-01578: ORACLE data block corrupted (file # 8, block # 22921) ORA-01110: data file 8: ...
1
vote
1answer
1k views

Does 'update global indexes' not work if the index is already unusable?

I have a partitioned table in Oracle 11g with a PK (global index). If I truncate one of the partitions with ALTER TABLE tbl1 TRUNCATE PARTITION p1; the global index has the status UNUSABLE. If I ...
6
votes
3answers
1k views

Clustered index in SQL Server vs index organized tables in Oracle

I am making the transition as a database developer from SQL Server to Oracle and found some fantastic resources here already (How to make a transition from SQL Server DBA to Oracle? and As a DBA, how ...
1
vote
1answer
354 views

Change a partitioned global non-unique index that is the primary key to a non-partitioned unique index

One of the largest tables in our system has its primary key setup as a globally ranged partitioned (in huge, useless, multi-billion value ranges) non-unique index. Its values are just a sequence ...
0
votes
1answer
182 views

What structure is used for storing CONTEXT, CTXCAT and CTXRULE Oracle text indexes?

AFAIK there are three major structure types used for storing Oracle index data: B-tree, R-tree and Bitmap. All indexes use one of these structures. However, not sure about CONTEXT, CTXCAT and CTXRULE ...
1
vote
2answers
177 views

What are the alternatives for prefixed indexes in Oracle?

You can create an index and define prefix length, so the index will store only first starting symbols from each of column value. It looks like this in MySQL: CREATE INDEX table_idx ON ...
0
votes
1answer
1k views

When hash indexes should be used in Oracle?

Hash indexes are usefull when you have a large table with URLs and you need to query by them. So, a solution would be to have an additional column "url_crc32" that will be filled with hashed URL value ...
4
votes
1answer
686 views

Does UPDATE INDEXES work for local indexes?

I have two tables in Oracle 11.2. First is partitioned and has local index (non-prefixed): CREATE TABLE table1 (col1 INT, col2 INT) PARTITION BY LIST(col1) ( PARTITION p1 VALUES(1), PARTITION ...
-2
votes
1answer
3k views

What are performance benefits when using number type instead of using char/varchar?

From various posts, I have summarized about using number type instead of char/varchar for PK: If you choose char/varchar type for PK and your values are short (just some alpha numberic codes) then it ...
1
vote
2answers
503 views

Would existing constraints and indexes applied to an old table, apply to a new table renamed like the old one after it's dropped?

everything is in the question. I have a table named tableA on which we have indexes and foreign keys and constraints. I have to modify content in a column called column1. This being a production ...
3
votes
2answers
433 views

What exactly is “pinning” in relation to indexes?

When one talks about "pinning" in indexes, what exactly is this? Is there some other word/term I can search for, as google has not provided any solutions. It is part of a test question, where ...
2
votes
1answer
765 views

Creating Bitmap Indexes on a Materialized View

I've been reading this article, discussing the benefits, tradeoffs, and potential problems with Bitmapped Indexes. It is mentioned: Also, remember that bitmap indexes are only suitable for static ...
0
votes
1answer
148 views

Creating Indexes to optimize query

I have this query and I want to increase its performance by adding appropriate Indexes. DELETE FROM MYTAB1 WHERE MYID1 IN ( SELECT MYID2 FROM MYTAB2 ); I am not familiar with the ...
1
vote
1answer
138 views

What is the performance difference between local text index and domain text index in oracle?

What is the performance difference between local text index and domain text index in oracle? Also what is the cost of rebuilding the domain text index when I have to split just one partition? Does the ...
11
votes
2answers
357 views

Are there any benefits in certain ordering of columns when defining indexes

For example, if I have two indexes: CREATE INDEX IDX_1 ON MY_TABLE_1 (ITEM, DATE, LOCATION) COMPUTE STATISTICS; CREATE INDEX IDX_2 ON MY_TABLE_1 (DATE, LOCATION, ITEM) COMPUTE STATISTICS; ...
4
votes
1answer
547 views

Why does it take a long time to drop a function based index in Oracle?

I have a function based index that takes 25 minutes to create on a table of 94 Million rows. When I drop the index, it takes 18 minutes. Why does it take so long? I would have thought the drop would ...
2
votes
2answers
911 views

How can Oracle use a Range Scan here?

I have a Customer table, with the columns "Name", "Location" and "DateMovedIn" (amongst others), which contains c. 20,000,000 rows. On this table, I have the index I_LOC_NAME_DATE, such that: Column ...
4
votes
4answers
664 views

How are foreign key indexes helpful?

How are foreign key indexes helpful? What is the criteria for keeping a foreign key index?
1
vote
1answer
1k views

At which frequency run CTXSYS.CTX_DDL.OPTIMIZE_INDEX(…) on a fulltext index?

I've been told to run periodically CTXSYS.CTX_DDL.OPTIMIZE_INDEX(...) on some fulltext indexes, with no more information, in particular at which frequency this task should be run. I guess that it ...
0
votes
1answer
126 views

oracle local partition index

I have a table like this: CREATE TABLE employees (employee_id NUMBER(4) NOT NULL, last_name VARCHAR2(10), department_id NUMBER(2)) PARTITION BY RANGE (department_id) (PARTITION employees_part1 ...
0
votes
1answer
1k views

oracle global index vs local index on a partitioned table

I have a table that has range partition by month on a date column (created_time). I was wondering what is more efficient of creating a global index on this column or creating a local index on this ...
3
votes
1answer
2k views

Oracle not using index when > used in where clause

We have a relatively classic scenario where the date clause of the query generated by the application uses a "greater than" for a given date. Because there is no end clause to the date range, oracle ...