创建物化视图时遇见bug 9369183:

简介:
做数据库同步实验的时候创建prebuilt mv 时 总是提示 ora-32349 ,查询metalink后,发现这是一个bug。。。。
yang@rac1>create materialized view yangtab2
  2   on prebuilt table refresh fast
  3   as select * from yangtab2@linkyang;
 create materialized view yangtab2
       *
ERROR at line 1:
ORA-32349: cannot reference prebuilt table in definition query for materialized view

yang@rac1>alter table yangtab2 add constraint pk_yangtab2 primary key (id);
Table altered.
yang@rac1>create materialized view yangtab2
  2   on prebuilt table refresh fast
  3   as select * from yangtab2@linkyang;
create materialized view yangtab2
       *
ERROR at line 1:
ORA-32349: cannot reference prebuilt table in definition query for materialized view
Bug 9369183: MVIEW WITH PREBUILT TABLE ON SELECT FROM REMOTE TABLE RETURNS ORA-32349     
显示 Bug 属性 Bug 属性
类型     B - Defect     已在产品版本中修复     12.1
严重性     2 - Severe Loss of Service     产品版本     11.2.0.1
状态     80 - Development to Q/A     平台     46 - Linux x86
创建时间     10-Feb-2010     平台版本     NO DATA
更新时间     23-Dec-2010     基本 Bug     6815375
数据库版本     11.2.0.1         
影响平台     Generic         
产品源     Oracle         

显示相关产品 相关产品
产品线     Oracle Database Products     系列     Oracle Database
区域     Oracle Database     产品     5 - Oracle Server - Enterprise Edition
Hdr: 9369183 11.2.0.1 RDBMS 11.2.0.1 MATERIAL_VIEW PRODID-5 PORTID-46 6815375
Abstract: MVIEW WITH PREBUILT TABLE ON SELECT FROM REMOTE TABLE RETURNS ORA-32349
*** 02/10/10 08:30 pm ***
  BUG TYPE CHOSEN
  ===============
  Code
  SubComponent: Materialized Views
  ================================
  DETAILED PROBLEM DESCRIPTION
  ============================
  The ability to create an materialized view on prebuilt table with the same
  name as a remote table exists in 9i, 10g, and 11R1, but does not exist in
  11R2, hence the creation of this bug for 11R2.
  Test scenario:  
  Create table as user ABC in 9i database, and as user ABC in 11R2 database
  (tested in 9.2.0.8 and 11.2.0.1):
  CREATE TABLE TEST
  ( ID NUMBER,
  VAL NUMBER,
  VAL2 VARCHAR2(30),
  VAL3 CLOB,
  PRIMARY KEY (ID));
 
  Create database link (tested private dblink for user ABC, connecting to ABC
  in remote db) from 11R2 to 9i.
  Create database link (tested private dblink for user ABC, connecting to ABC
  in remote db) from 9i to 11R2.
  In 9i, as user ABC, issue:
  CREATE MATERIALIZED VIEW TEST ON PREBUILT TABLE FOR UPDATE AS SELECT * FROM
  TEST@;
  Materialized view created.
  -  Note that the mview/prebuilt table have the same name/same schema as the
  remote table in select clause of definition query
  -  You can do the above test above in 10g and 11R1, and you will be able to
  successfully create the mview.
  -  Please also note that you can successfully create the mview if the Test
  table exists locally but in a different schema.
 
  Drop the mview, then do the following: 
  In 11R2, as user ABC, issue:
 
  CREATE MATERIALIZED VIEW TEST ON PREBUILT TABLE FOR UPDATE AS SELECT * FROM
  TEST@STRM92P
       *
  ERROR at line 1:
  ORA-32349: cannot reference prebuilt table in definition query for
  materialized view
  -  This error is returned for this test in 11R2 only.
 
  Note that Bug 6815375 addressed an ORA-4020 returned on creation of mview
  with prebuilt table where prebuilt table is referenced as local table in
  definition query.  This bug was resolved with return of ORA-32349 for
  action.  Unfortunately, this error is now returned on mview with prebuilt
  table where prebuilt table is referenced as remote table in definition query
  (where the ORA-4020 did not occur in prior releases). 
  DIAGNOSTIC ANALYSIS
  ===================
  See above 
  WORKAROUND?
  ===========
  Yes 
  WORKAROUND INFORMATION
  ======================
  Create prebuilt table using different name as remote table in definition
  query.  However, for customer of this bug, plan is to drop mview in future
  with resultant change of prebuilt table to regular table - customer wants
  this table to have same name as remote table.  This is a reasonable request,
  as this worked previously without ORA-4020 or other error.
 
  TECHNICAL IMPACT
  ================
  See above
  RELATED ISSUES (bugs, forums, RFAs)
  ===================================
  Bug 6815375 - ATTEMPT TO CREATE A MV WITH 'ON PREBUILT TABLE' RESULTS IN A
  DEADLOCK
  HOW OFTEN DOES THE ISSUE REPRODUCE AT CUSTOMER SITE?
  ====================================================
  Always
 
  DOES THE ISSUE REPRODUCE INTERNALLY?
  ====================================
  Always
  IS A TESTCASE AVAILABLE?
  ========================
  Yes 
相关文章
|
2天前
|
人工智能 运维 安全
|
4天前
|
SpringCloudAlibaba 负载均衡 Dubbo
微服务架构下Feign和Dubbo的性能大比拼,到底鹿死谁手?
本文对比分析了SpringCloudAlibaba框架下Feign与Dubbo的服务调用性能及差异。Feign基于HTTP协议,使用简单,适合轻量级微服务架构;Dubbo采用RPC通信,性能更优,支持丰富的服务治理功能。通过实际测试,Dubbo在调用性能、负载均衡和服务发现方面表现更出色。两者各有适用场景,可根据项目需求灵活选择。
381 124
微服务架构下Feign和Dubbo的性能大比拼,到底鹿死谁手?
|
7天前
|
人工智能 JavaScript 测试技术
Qwen3-Coder入门教程|10分钟搞定安装配置
Qwen3-Coder 挑战赛简介:无论你是编程小白还是办公达人,都能通过本教程快速上手 Qwen-Code CLI,利用 AI 轻松实现代码编写、文档处理等任务。内容涵盖 API 配置、CLI 安装及多种实用案例,助你提升效率,体验智能编码的乐趣。
657 107
|
1天前
|
算法 Python
【轴承故障诊断】一种用于轴承故障诊断的稀疏贝叶斯学习(SBL),两种群稀疏学习算法来提取故障脉冲,第一种仅利用故障脉冲的群稀疏性,第二种则利用故障脉冲的额外周期性行为(Matlab代码实现)
【轴承故障诊断】一种用于轴承故障诊断的稀疏贝叶斯学习(SBL),两种群稀疏学习算法来提取故障脉冲,第一种仅利用故障脉冲的群稀疏性,第二种则利用故障脉冲的额外周期性行为(Matlab代码实现)
221 152
|
3天前
|
Java 数据库 数据安全/隐私保护
Spring 微服务和多租户:处理多个客户端
本文介绍了如何在 Spring Boot 微服务架构中实现多租户。多租户允许单个应用实例为多个客户提供独立服务,尤其适用于 SaaS 应用。文章探讨了多租户的类型、优势与挑战,并详细说明了如何通过 Spring Boot 的灵活配置实现租户隔离、动态租户管理及数据源路由,同时确保数据安全与系统可扩展性。结合微服务的优势,开发者可以构建高效、可维护的多租户系统。
200 127
|
3天前
|
Web App开发 前端开发 API
在折叠屏应用中,如何处理不同屏幕尺寸和设备类型的样式兼容性?
在折叠屏应用中,如何处理不同屏幕尺寸和设备类型的样式兼容性?
229 124
|
1天前
|
编解码 算法 自动驾驶
【雷达通信】用于集成传感和通信的OFDM雷达传感算法(Matlab代码实现)
【雷达通信】用于集成传感和通信的OFDM雷达传感算法(Matlab代码实现)
172 125
|
1天前
|
JavaScript 关系型数据库 MySQL
基于python的网上外卖订餐系统
本系统基于Python与Flask框架,结合MySQL数据库及Vue前端技术,实现了一个功能完善的网上订餐平台。系统涵盖餐品、订单、用户及评价管理模块,并深入研究订餐系统的商业模式、用户行为与服务质量。技术上采用HTML、PyCharm开发工具,支持移动端访问,助力餐饮业数字化转型。