Hi,

Connect sys

For the creation of a function-based index in your own schema, you must be
granted the CREATE INDEX and QUERY REWRITE system privileges. To create the
index in another schema or on another schema's tables, you must have the
CREATE ANY INDEX and GLOBAL QUERY REWRITE privileges.

You must have the following initialization parameters defined to create a
function-based index:

QUERY_REWRITE_INTEGRITY must be set to TRUSTED

QUERY_REWRITE_ENABLED must be set to TRUE

COMPATIBLE must set to 8.1.0.0.0 or a greater value


The result :

SQL> create index myfindex on emp(income/0);
create index myfindex on emp(income/0)
                                   *
ERROR at line 1:
ORA-01476: divisor is equal to zero



Sinardy

-----Original Message-----
Sent: 05 March 2002 16:38
To: Multiple recipients of list ORACLE-L


Hi guys,


This is my test:


SQL> desc emp
 Name                                      Null?    Type
 ----------------------------------------- -------- ------------------------
----
 EMPNO                                     NOT NULL CHAR(3)
 NAME                                               VARCHAR2(10)
 INCOME                                             NUMBER(5)

SQL> create index no_logic on emp(income);

Index created.

SQL> drop index no_logic;

Index dropped.

SQL> create index wrong_logic on emp(income/0);
create index wrong_logic on emp(income/0)
                                       *
ERROR at line 1:
ORA-01031: insufficient privileges



I don't understand why Oracle throw such exception (reply).
Do you have any idea what is Oracle doing when Oracle find out number / 0



Sinardy

--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Sinard Xing
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Sinard Xing
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to