Skip to Main Content
  • Questions
  • Use cases for savepoint, views, materialized views and indexes

Breadcrumb

Question and Answer

Connor McDonald

Thanks for the question, shiva.

Asked: May 05, 2016 - 5:12 am UTC

Last updated: May 05, 2016 - 6:46 am UTC

Version: 11g

Viewed 1000+ times

You Asked

Hi Tom,

Just wanted to know where we will use save point in live scenarios and views and materialized views. ?

is updating a view updates a table?

is index we will create or oracle creates for us automaticlally, in case if we have to create a index how we will create and which type of index will decide to create in what situations?

your answer will be highly appreciated...


Thank you,
Regards,
Shiva

and Connor said...

1) savepoints

Here is an asktom thread describing savepoints and potentials uses:

https://asktom.oracle.com/pls/apex/f?p=100:11:0::::P11_QUESTION_ID:496653103575

2) updating a view

If the view maps directly to a table, (or one of the tables in the definition), but that I mean, the row in the view has 1-to-1 with the row in the table based on its primary key definition, then you probably will be able to update the view (and the table will be updated).

More info here https://asktom.oracle.com/pls/apex/f?p=100:11:0::::P11_QUESTION_ID:548422757486

3) materialized views

As the name suggests, we take the SQL from a view, actually run it and store (materialize) the results. We might choose to do this when the SQL takes a long time to run, and lots of people want to run it. So it may be more efficient to run it once and store the results, and point people at that.

4) indexes

Oracle auto-creates indexes for you in *some* circumstances, to enforce a primary key or uniqueness constraints. You can create indexes for other reasons as well, but that's a very big topic. I'd suggest you take a read on the indexes section in the Concepts guide.

Rating

  (1 rating)

Is this answer out of date? If it is, please let us know via a Comment

Comments

Great

Shiva, May 05, 2016 - 6:53 am UTC

Very helpful guide on the web