久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

Oracle 視圖與 Oracle 中的連接表

Oracle View vs joining tables in Oracle(Oracle 視圖與 Oracle 中的連接表)
本文介紹了Oracle 視圖與 Oracle 中的連接表的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

問題描述

限時送ChatGPT賬號..

我知道視圖是 Oracle 中底層表或表集的窗口.例如,如果我有一個通過連接多個表創建的視圖,當我從視圖中選擇數據時,視圖會執行實際的連接操作嗎?視圖的性能是否比連接多個表來獲取數據更好?在性能方面是否相同?

I understand that a view is a window to an underlying table or set of tables in Oracle. For instance if I have a view that is created by joining multiple tables , will the view perform the actual join operations when I select data from the view? Does a view perform better than joining multiple tables to fetch data or is it the same with respect to performance?

推薦答案

單個查詢和使用視圖的邏輯等效查詢之間通常沒有性能差異.

There is usually no performance difference between a single query and a logically equivalent query that uses views.

Oracle 具有優化器轉換,可以將視圖與外部查詢結合起來;謂詞推送、簡單和復雜的視圖合并等.將視圖視為構建大型查詢的文本宏,而不是返回行的函數.

Oracle has optimizer transformations that can combine views with the outer query; predicate pushing, simple and complex view merging, etc. Think of views more like a text macro that builds a large query, instead of a function that returns rows.

例如,在下面的查詢中,Oracle 可能足夠聰明,可以將主鍵列上的謂詞推送到視圖中.盡管視圖本身可能會返回數百萬行,但是當整個查詢運行時,Oracle 將首先在主鍵列上應用謂詞.

For example, in the below query Oracle would probably be smart enough to push the predicate on the primary key column into the view. Although the view by itself might return millions of rows, when the entire query is run Oracle will apply the predicate on the primary key column first.

select *
from view_returns_millions_of_rows
where primary_key_value = 1;

這篇關于Oracle 視圖與 Oracle 中的連接表的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

相關文檔推薦

What SQL Server Datatype Should I Use To Store A Byte[](我應該使用什么 SQL Server 數據類型來存儲字節 [])
Interpreting type codes in sys.objects in SQL Server(解釋 SQL Server 中 sys.objects 中的類型代碼)
Typeorm .loadRelationCountAndMap returns zeros(Typeorm .loadRelationCountAndMap 返回零)
How to convert #39;2016-07-01 01:12:22 PM#39; to #39;2016-07-01 13:12:22#39; hour format?(如何將“2016-07-01 01:12:22 PM轉換為“2016-07-01 13:12:22小時格式?)
Convert multiple sub-queries to on join(將多個子查詢轉換為 on join)
How do I get the minute difference between 2 times in T SQL?(如何獲得 T SQL 中 2 次之間的微小差異?)
主站蜘蛛池模板: 久久人人爽人人爽人人片av免费 | 精品伦精品一区二区三区视频 | 二区在线视频 | 欧美日韩电影一区二区 | 青青久在线视频 | 国产在线精品一区二区三区 | 国产高清精品一区二区三区 | 久久久91精品国产一区二区精品 | 精品日韩一区二区 | 久久久黑人| 久久精品一区二区 | 一级黄色毛片免费 | 午夜在线小视频 | 久久国产视频网站 | a级黄色网| 国产美女在线观看 | 一级在线毛片 | 欧美成人手机视频 | 精品一区在线看 | 日韩欧美三级在线 | 香蕉一区 | 荷兰欧美一级毛片 | 日本欧美在线 | 国产成人综合av | 亚洲国产精品久久久久久 | 亚洲综合电影 | 国产精品久久久久无码av | 国产精品日本一区二区在线播放 | 一区二区三区四区视频 | 国产伦精品一区二区三区高清 | 亚洲视频在线看 | 99久久99 | 久久久久国产一区二区三区 | 亚洲欧美日韩在线 | 久草免费在线视频 | 欧美成人一级 | 亚洲+变态+欧美+另类+精品 | 国产精品69毛片高清亚洲 | 色综合久| 欧美久久一区 | 99精品久久 |