Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Corporate Acceptance of Creating Views ?

Re: Corporate Acceptance of Creating Views ?

From: Vincent <vincent_thangaraj_at_cpr.satyam.com>
Date: 30 Oct 2001 21:53:44 -0800
Message-ID: <7cb11077.0110302153.5f5a792f@posting.google.com>


"Sybrand Bakker" <postbus_at_sybrandb.demon.nl> wrote in message news:<ttspeo9frv6h80_at_corp.supernews.com>...
> "jane" <janeyiu_at_optonline.net> wrote in message
> news:eQoD7.43362$C7.13166440_at_news02.optonline.net...
> > Is it true that in general corporate enviornment, the use of Views is
> > discouraged ? even frowned up ?
> >
> > I was working with this "seasoned" developer on developing reports, I am
> new
> > to the Oracle enviornment
> > and she insisted that I should NOT use views if at all possible,
> preferablly
> > not at all.
> >
> > "You should be able to get all the data you need with straight SQL...even
> if
> > it have to go for pages !"
> > "...you are creating yet another dependency...it's another object that has
> > to be maintained !......"
> >
> > The thing was with tools like Crystal Reports, it does not handle manual
> SQL
> > very well (requires
> > a separate file to store the query)
> >
> > Is this true ? Was she full of bs ?
> >
> > thanks
> > jane
> >
> >
> No she wasn't full of bs. Her obvious concern was you were going to create
> individual views for individual reports.
> As views nowadays have to be compiled (a select * is resolved at
> compile-time, not at run-time) her concern about another level of dependency
> is correct.
>
> Hth,

I agree with Sybrand on this one...
Here's an extract from ixora regarding overhead of using views...

Oracle does not cache view definitions in the library cache or dictionary cache. They have to be fetched from the data dictionary every time that a statement that references views is parsed. If this happens frequently enough, then the database blocks containing the view definitions may be retained in the buffer cache. Otherwise, physical I/O is required to read the view definition.

If the application is expected to parse new SQL statements consistently and has moderate to high concurrency requirements, then I would say that this overhead is significant enough to make you avoid the use of unnecessary views. Otherwise, it does not matter very much. I dislike any unnecessary overhead, so I would avoid the views anyway. If you later find a real reason to interpose views, then the RENAME command gives you an elegant way of introducing them without changing the code; so you may as well do without them at least initially

Regards,
Vincent. Received on Tue Oct 30 2001 - 23:53:44 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US