惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

人人都是产品经理
人人都是产品经理
aimingoo的专栏
aimingoo的专栏
Y
Y Combinator Blog
B
Blog
D
Docker
C
Check Point Blog
A
About on SuperTechFans
云风的 BLOG
云风的 BLOG
F
Fortinet All Blogs
Stack Overflow Blog
Stack Overflow Blog
Recent Announcements
Recent Announcements
MongoDB | Blog
MongoDB | Blog
WordPress大学
WordPress大学
Jina AI
Jina AI
罗磊的独立博客
月光博客
月光博客
博客园 - Franky
L
LangChain Blog
H
Help Net Security
Google DeepMind News
Google DeepMind News
Microsoft Security Blog
Microsoft Security Blog
小众软件
小众软件
T
Tailwind CSS Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻

博客园 - 土鸟

微信挪车功能成功上线,祝贺一下自己 Form personization(Form 个性化)报无权限 (OSP)外包工单关工单失败 failed jobs because of past close date,关工单报错 APP-BOM-20516 错误处理一例 Some User Can Not Execute "Ship Confirm"(Doc ID 473312.1) Oracle Purchasing QUESTIONS AND ANSWERS 符合中国人习惯的oracle取周的日期函数 Form开发中Block的顺序 关于Forms_ddl的应用 Form开发技巧二-----SPECIAL1菜单编成 Form开发技巧一 ------- 相同ORG只允许同时一个Session作业 提高电脑运行速度---清理内存工具 Oracle ADI 错误及解决方式汇总---来自metalink Oracle EBS付款条件 Examples To howto Insert into Transaction Open Interface 传说中的蹭网卡 无法建BOM APP-SQLGL-08252异常处理
Outer Join Query Over Dblink Can Fail With ORA-904 (Doc I...
土鸟 · 2014-06-06 · via 博客园 - 土鸟

In this Document

  Symptoms
  Changes
  Cause
  Solution
  References

APPLIES TO:

Oracle Database - Enterprise Edition - Version 10.2.0.1 to 11.1.0.7 [Release 10.2 to 11.1]
Information in this document applies to any platform.

SYMPTOMS

Following query over dblink having Local database 9iR2 and remote 10gR2 works..

select *
from ctps3.institutions@ctps3 i,
ctps3.state_types@ctps3 s,ods.institutions oi
where s.stt_state_type_id (+) = i.stt_state_type_id
and oi.ctps_insttn_id = i.inst_insttn_id
and i.inst_modifd_dt = trunc(sysdate)
and (nvl (oi.inst_state_txt, 'x') <> nvl (s.stt_state_type_nm, 'x'))
and (nvl (oi.inst_phone_txt, 17) <> nvl (i.inst_phone_txt, 17));

The same query fails when both local and remote databases are 10g R2, with following errors:

ERROR at line 2:
ORA-00904: "OI"."INST_STATE_TXT": invalid identifier
ORA-02063: preceding line from CTPS3

CHANGES

CAUSE

Outer join query over dblink can fail with ORA-904, as referenced in:

BUG 6620988 QUERY OVER DBLINK FAILS WITH ORA-904 SELECTING DATE

Predicates are not checked to verify if they belong to same network node when we attempt to colocate the remote tables. This results in wrongly generating remote query and ORA-904

REDISCOVERY INFORMATION:
1. ORA-904
2. DB link
3. OJ predicates across network nodes
4. predicates wrongly pushed network nodes

SOLUTION

-- To implement the solution, please execute the following steps::

Use the workaround of disabling colocated joins via event 10176 and force a hard parse to happen
(ie by flushing the shared pool), ie:

SQL> alter session set events '10176 trace name context forever';
SQL> alter system flush shared_pool;

or

For a permanent fix, request a One-Off Backport of 6620988 for the appropiate platform.

REFERENCES

BUG:6620988 - QUERY OVER DBLINK FAILS WITH ORA-904 SELECTING DATE

欢迎转载,但请注明出处!

posted @ 2014-06-06 10:49  土鸟  阅读(1076)  评论()    收藏  举报