What is the difference between Views and Materialized Views in Oracle?

前端 未结 8 2096
一向
一向 2020-12-02 03:35

What is the difference between Views and Materialized Views in Oracle?

8条回答
  •  再見小時候
    2020-12-02 04:00

    Adding to Mike McAllister's pretty-thorough answer...

    Materialized views can only be set to refresh automatically through the database detecting changes when the view query is considered simple by the compiler. If it's considered too complex, it won't be able to set up what are essentially internal triggers to track changes in the source tables to only update the changed rows in the mview table.

    When you create a materialized view, you'll find that Oracle creates both the mview and as a table with the same name, which can make things confusing.

提交回复
热议问题