Maybe the IN clause is throwing it?
Try it with -
where trans_type = 'A' or trans_type = 'B'
Just a WAG...
Beth
-----Original Message-----
Sent: Monday, September 09, 2002 2:38 PM
To: Multiple recipients of list ORACLE-L
Hi all,
Using 8.1.7.4.0 on HP/UX with COMPATIBILE set to "8.1.7", I'm not able
to
create the following simple MV:
CREATE MATERIALIZED VIEW qt_gl_trans_ab_mv
TABLESPACE qt_mat_view
BUILD IMMEDIATE
USING INDEX TABLESPACE qt_mat_view PCTFREE 15 INITRANS 2
REFRESH FAST WITH ROWID
USING LOCAL ROLLBACK SEGMENT rbsbig
START WITH SYSDATE
NEXT (TRUNC(SYSDATE+1) + 4/24)
AS
select fiscal_year, fiscal_period, account_no,
trans_type, trans_amount
from my_general_ledge
where trans_type in ('A','B')
It errors with ORA-12015 "cannot create a fast refresh snapshot from a
complex query". According to MetaLink doc 179466.1, a complex query in
a MV
on 8.1.7 is one that has at least one of:
- a distinct or unique keyword
- an aggregate function (e.g. avg, count, max, min, sum, ....)
- a connect by clause
- a group by or order by clause
- a set operator (UNION, UNION ALL, INTERSECT and MINUS)
- joins other than those in a subquery
But my query has none of those? Thinking somethings hosed or I'm
completely
misunderstanding the "IN" operator of the WHERE clause, I tried "where
trans_type = 'A'", but with the same results.
Also, I've created the MV log for the fast refresh:
CREATE MATERIALIZED VIEW LOG ON my_general_ledger
WITH ROWID
I'm just testing out MVs here, but I'm missing something real simple
and/or
stupid here, but for the life of me I can't see what (even after a lunch
break).
Anyone?
Rich Jesse System/Database Administrator
[EMAIL PROTECTED] Quad/Tech International, Sussex, WI
USA
--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Jesse, Rich
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: Seefelt, Beth
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).