My Oracle Support Banner

Materialized View Creation on Prebuilt Table Fails with ORA-12060 (Doc ID 1379574.1)

Last updated on FEBRUARY 03, 2019

Applies to:

Oracle Database - Enterprise Edition - Version 10.2.0.4 to 11.2.0.2 [Release 10.2 to 11.2]
Information in this document applies to any platform.

Symptoms

SQL>create table
MV_RPCA_RTG_PRE_COST_AGG (
ROUTE_CD number);

SQL> create table MV_RCSM_RTG_PFRM_COST_SUM_X
AS
SELECT CUR_MIN_ROUTE_CD
FROM
( SELECT ROUTE_CD AS CUR_MIN_ROUTE_CD
FROM MV_RPCA_RTG_PRE_COST_AGG
) RCSM;

SQL> CREATE MATERIALIZED VIEW MV_RCSM_RTG_PFRM_COST_SUM_X
--BUILD DEFERRED
ON PREBUILT TABLE WITH REDUCED PRECISION
AS
SELECT CUR_MIN_ROUTE_CD
FROM
( SELECT ROUTE_CD AS CUR_MIN_ROUTE_CD
FROM MV_RPCA_RTG_PRE_COST_AGG
) RCSM;

ERROR at line 5: ORA-12060: shape of prebuilt table does not match definition query



No such problem(error) if the column wasn't aliased.

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.