日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

oracle opaque_transform,oracle databse link

發布時間:2023/12/15 编程问答 30 豆豆
生活随笔 收集整理的這篇文章主要介紹了 oracle opaque_transform,oracle databse link 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

關于這個hint 是10.2.0.3 之后出現的,在insert into table select * from [email?protected]_link 這一類型的語句, 在執行時,源端數據庫中出現的。

在MOS doc ID 780503.1 中對此有說明。文檔內容如下:

Applies to:

Oracle Server - Enterprise Edition - Version: 10.2.0.3 and later

Information in this document applies to any platform.

Oracle Server Enterprise Edition - Version: 10.2.0.3

***Checked for relevance on 02-MAR-2012***

Goal

What is OPAQUE_TRANSFORM usage :

The OPAQUE_TRANSFORM hint is to help with the transformation of datatype when certain

type of operations are done within the database. For example object types .

It is also used for a insert-as-remote-select operation on a remote database

Example : insert into emp (select * from [email?protected]) ;

call count cpu elapsed disk query current rows

------- ------ -------- ---------- ---------- ---------- ---------- ----------

Parse 1 0.00 0.50 0 0 0 0

Execute 1 0.00 0.51 0 1 44 12

Fetch 0 0.00 0.00 0 0 0 0

------- ------ -------- ---------- ---------- ---------- ---------- ----------

total 2 0.00 1.01 0 1 44 12

Misses in library cache during parse: 0

Optimizer mode: ALL_ROWS

Parsing user id: 57 (SCOTT)

Rows Row Source Operation

------- ---------------------------------------------------

12 REMOTE EMP (cr=0 pr=0 pw=0 time=508808 us)

Rows Execution Plan

------- ---------------------------------------------------

0 INSERT STATEMENT MODE: ALL_ROWS

12 REMOTE OF ‘EMP‘ (REMOTE) [REP102B]

SELECT /*+ OPAQUE_TRANSFORM */ "EMPNO","ENAME","JOB","MGR",

"HIREDATE","SAL","COMM","DEPTNO" FROM "EMP" "EMP"

Note : This hint should not interfere with the query optimizer plan.

Solution

The below event can be set on the client (local) in order to turn the opaque_transform hint on and off..

- To switch on :

alter session set events ‘22825 trace name context off‘ ;

- To switch off :

1) alter session set events ‘22825 trace name context forever, level 1‘ ;

2) or using the following hint : /*+ NO_QUERY_TRANSFORMATION */

3) using RULE hint.

-Note that if local site is 11g and remote is 11g server, this opens 2 sessions

on the remote database and OPAQUE_TRANSFORM hint gives DX LOCK deadlock.

- If the local is 10g client and remote is 11g server, this opens 1 session on

the remote and no DX deadlock.

總結

以上是生活随笔為你收集整理的oracle opaque_transform,oracle databse link的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。