I have a table with an identifier column (code) and a value column(val).
I have a functional materialized view on oracle 11g :
CREATE MATERIALIZED VIEW "MYVIEW"
BUILD IMMEDIATE
REFRESH fast ON demand
WITH ROWID
AS
SELECT
code,
sum(val)
FROM mytable
GROUP BY code
;
But if i edit like this (just add "+10" to the sum column) :
CREATE MATERIALIZED VIEW "MYVIEW"
BUILD IMMEDIATE
REFRESH fast ON demand
WITH ROWID
AS
SELECT
code,
sum(val) +10
FROM mytable
GROUP BY code
;
I have an error :
ORA-12015: cannot create a fast refresh materialized view from a complex query
Why ??