Materialized View Vs Table functions [message #383609] |
Thu, 29 January 2009 05:26 |
sundaravel_n
Messages: 6 Registered: October 2007
|
Junior Member |
|
|
hi,
I need one clarification, which is giving better performance ? whether Materialized view or Table functions ?
Both will return some set of rows like 100,1000,10,000.
In our project, we are using Mviews to give some set of records, instead of using select query, its developed before 3 years, they are telling the reason why they have created Mview is it will stored in cache, it will give better performance than "Normal select query", ok, i am able to understand this point.
Now i have red that Table function also can able to return, some set of records like a " normal select query",
can we use it instead of Materialize view. ???
But which one will give better performance.
Thanks
Sundaravel N
|
|
|
|
Re: Materialized View Vs Table functions [message #383620 is a reply to message #383609] |
Thu, 29 January 2009 05:48 |
JRowbottom
Messages: 5933 Registered: June 2006 Location: Sunny North Yorkshire, ho...
|
Senior Member |
|
|
The big advantage of Mviews is that they let you perform complex queries ahead of time, and provide you with a materialized set of results that you can query from a single source, rather than having to go to all the individual tables every time. The blocks in the Mview can be cached in just the same way as blocks from a table.
The TABLE function lets you use a collection as a datasource for a quuery. It's pretty performant, but the problem is that yo uwill have to go and populate the collection , which will take time if the data source is a complex query.
|
|
|