Wednesday, January 7, 2009

分布式sql(事务)的一些限制

分布式sql(事务)的一些限制
2008-03-26 16:35

在通过db link的分布事查询中有一些限制,Database Administrator's Guide有说明

1.Data manipulation language statements that update objects on a remote non-Oracle
Database system cannot reference any objects on the local Oracle Database.
For example, a statement such as the following will cause an error to be raised:

INSERT INTO remote_table@link as SELECT * FROM local_table;

2.Within a single SQL statement, all referenced LONG and LONG RAW columns, sequences, updated tables, and locked tables must be located at the same node.

3.The database does not allow remote DDL statements (for example, CREATE, ALTER,
and DROP) in homogeneous systems except through remote execution of procedures of
the DBMS_SQL package, as in this example:

DBMS_SQL.PARSE@link_name(crs, 'drop table emp', v7);

Note that in Heterogeneous Systems, a pass-through facility lets you execute DDL.

4.The LIST CHAINED ROWS clause of an ANALYZE statement cannot reference remote tables.

5.In a distributed database system, the database always evaluates environmentally-dependent
SQL functions such as SYSDATE, USER, UID, and USERENV with respect to the local server,
no matter where the statement (or portion of a statement) executes.


A number of performance restrictions relate to access of remote objects:

6.Remote views do not have statistical data.

7.Queries on partitioned tables may not be optimized.

8.No more than 20 indexes are considered for a remote table.

9.No more than 20 columns are used for a composite index.

10.There is a restriction in the Oracle Database implementation of distributed read consistency that can cause one node to be in the past with respect to another node. In accordance with read consistency, a query may end up retrieving consistent, but out-of-date data. (为了保证访问一致性,可能有些查出来的数据是过期数据)

No comments:

Post a Comment