Refresh Materialized Views (189)
Oracle maintains the data in materialized views by refreshing them after changes aremade to their master tables. The refresh method can be incremental (fast refresh) orcomplete. For materialized views that use the fast refresh method, a materialized viewlog or direct loader log keeps a record of changes to the master tables.Materialized views can be refreshed either on demand or at regular time intervals.Alternatively, materialized views in the same database as their master tables can berefreshe
Define Constraints on Views (188)
Data warehousing applications recognize multidimensional data in the Oracledatabase by identifying Referential Integrity (RI) constraints in the relational schema.RI constraints represent primary and foreign key relationships among tables. Byquerying the Oracle data dictionary, applications can recognize RI constraints andtherefore recognize the multidimensional data in the database. In some environments,database administrators, for schema complexity or security reasons, define views onfact and
Materialized Views in mobile computing environment (187)
In mobile computing environments, materialized views are used to download asubset of data from central servers to mobile clients, with periodic refreshes fromthe central servers and propagation of updates by clients back to the centralservers.数据计算环境下的物化视图在移动计算环境中,移动客户端可以使用物化视图从中央服务器下载一个数据的子集,还可以定期地从中央服务器取得最新数据,并将移动客户端的数据修改传回中央服务器.[@more@]
Materialized Views in data distributed environment (186)
In distributed environments, materialized views are used to replicate data atdistributed sites and synchronize updates done at several sites with conflictresolution methods. The materialized views as replicas provide local access to datathat otherwise has to be accessed from remote sites.分布式环境下的物化视图在分布式环境中,用户可以使用物化视图提供的功能在各个分布的节点间复制数据, 同步各个节点修改的数据 物化视图可以将远程节点访问的数据复制到本地节点[@more@]
Materialized Views in data warehouse environment (185)
In data warehouses, materialized views are used to compute and store aggregateddata such as sums and averages. Materialized views in these environments aretypically referred to as summaries because they store summarized data. They canalso be used to compute joins with or without aggregations. If compatibility is setto Oracle9i or higher, then materialized views can be used for queries that includefilter selections.The optimizer can use materialized views to improve query performance byautomatica
Overview of Materialized Views (184)
Materialized views are schema objects that can be used to summarize, compute,replicate, and distribute data. They are suitable in various computing environmentssuch as data warehousing, decision support, and distributed or mobile computing.Materialized views are similar to indexes in several ways:■ They consume storage space.■ They must be refreshed when the data in their master tables changes.■ They improve the performance of SQL execution when they are used for queryrewrites.■ Their existe
Inline Views (183)
An inline view is not a schema object. It is a subquery with an alias (correlation name)that you can use like a view within a SQL statement.内联视图1. 不是方案对象2. 是一个拥有别名的子查询 , 用户可以在 SQL 语句中将她作为一个视图来使用[@more@]
Object Views (182)
In the Oracle object-relational database, an object view let you retrieve, update, insert,and delete relational data as if it was stored as an object type. You can also defineviews with columns that are object datatypes, such as objects, REFs, and collections(nested tables and VARRAYs).对象视图1. 在 Oracle 的对象-关系型数据库中,利用对象视图就可以像操作对象类型一样对关系型数据进行DML操作2. 用户定义的视图中也可以包含对象数据类型的列,常用的对象数据类型有对象 , REFs等[@more@]
Updatable Join Views (181)
A join view is defined as a view that has more than one table or view in its FROMclause (a join) and that does not use any of these clauses: DISTINCT, aggregation,GROUP BY, START WITH, CONNECT BY, ROWNUM, and set operations (UNION ALL,INTERSECT, and so on).An updatable join view is a join view that involves two or more base tables or views,where UPDATE, INSERT, and DELETE operations are permitted. The data dictionaryviews ALL_UPDATABLE_COLUMNS, DBA_UPDATABLE_COLUMNS, and USER_UPDATABLE_COLUMNS c
Dependencies and Views (180)
Because a view is defined by a query that references other objects (tables, materializedviews, or other views), a view depends on the referenced objects. Oracle automaticallyhandles the dependencies for views. For example, if you drop a base table of a viewand then create it again, Oracle determines whether the new base table is acceptable tothe existing definition of the view.视图的依赖性1. 由于视图的定义是一个引用了其他对象的查询,因此视图依赖于其所引用的对象 2. Oracle 会自动地处理视图的依
Use of Indexes Against Views (179)
Oracle determines whether to use indexes for a query against a view by transformingthe original query when merging it with the view’s defining query.In all possible cases, Oracle merges a query against a view with the view’s definingquery and those of any underlying views. Oracle optimizes the merged query as if youissued the query without referencing the views. Therefore, Oracle can use indexes onany referenced base table columns, whether the columns are referenced in the viewdefinition or in
Globalization Support Parameters in Views (178)
When Oracle evaluates views containing string literals or SQL functions that haveglobalization support parameters as arguments (such as TO_CHAR, TO_DATE, and TO_NUMBER), Oracle takes default values for these parameters from the globalizationsupport parameters for the session. You can override these default values byspecifying globalization support parameters explicitly in the view definition.视图中的国际化支持参数当 Oracle 发现视图中存在使用国际化支持参数的 SQL 函数或字符串型符号时,Oracle将使用当
Mechanics of Views (177)
Oracle stores a view’s definition in the data dictionary as the text of the query thatdefines the view. When you reference a view in a SQL statement, Oracle:1. Merges the statement that references the view with the query that defines the view2. Parses the merged statement in a shared SQL area3. Executes the statementOracle parses a statement that references a view in a new shared SQL area only if noexisting shared SQL area contains a similar statement. Therefore, you get the benefit ofreduced m
How Views Are Used (176)
Views provide a means to present a different representation of the data that resideswithin the base tables. Views are very powerful because they let you tailor thepresentation of data to different types of users. Views are often used to:■ Provide an additional level of table security by restricting access to apredetermined set of rows or columns of a table■ Hide data complexity■ Simplify statements for the user■ Present the data in a different perspective from that of the base table■ Isolat
How Views are Stored (175)
Unlike a table, a view is not allocated any storage space, nor does a view actuallycontain data. Rather, a view is defined by a query that extracts or derives data from thetables that the view references. These tables are called base tables. Base tables can inturn be actual tables or can be views themselves (including materialized views).Because a view is based on other objects, a view requires no storage other than storagefor the definition of the view (the stored query) in the data dictionary.
Overview of Views (174)
A view is a tailored presentation of the data contained in one or more tables or otherviews. A view takes the output of a query and treats it as a table. Therefore, a view canbe thought of as a stored query or a virtual table. You can use views in most placeswhere a table can be used.Because views are derived from tables, they have many similarities. For example, youcan define views with up to 1000 columns, just like a table. You can query views, andwith some restrictions you can update, insert
Parallel Access to External Tables (173)
After the metadata for an external table is created, you can query the external datadirectly and in parallel, using SQL. As a result, the external table acts as a view, whichlets you run any SQL query against external data without loading the external datainto the database.The degree of parallel access to an external table is specified using standard parallelhints and with the PARALLEL clause. Using parallelism on an external table allows forconcurrent access to the datafiles that comprise an ex
Data Loading with External Tables (172)
The main use for external tables is to use them as a row source for loading data into anactual table in the database. After you create an external table, you can then use aCREATE TABLE AS SELECT or INSERT INTO ... AS SELECT statement, using theexternal table as the source of the SELECT clause.When you access the external table through a SQL statement, the fields of the externaltable can be used just like any other field in a regular table. In particular, you can usethe fields as arguments for an
The Access Driver (171)
When you create an external table, you specify its type. Each type of external table hasits own access driver that provides access parameters unique to that type of externaltable. The access driver ensures that data from the data source is processed so that itmatches the definition of the external table.In the context of external tables, loading data refers to the act of reading data from anexternal table and loading it into a table in the database. Unloading data refers to theact of reading dat
External Tables (170)
External tables access data in external sources as if it were in a table in the database.You can connect to the database and create metadata for the external table using DDL.The DDL for an external table consists of two parts: one part that describes the Oraclecolumn types, and another part (the access parameters) that describes the mapping ofthe external data to the Oracle data columns.An external table does not describe any data that is stored in the database. Nor does itdescribe how data is s