Home » SQL & PL/SQL » SQL & PL/SQL » compile invalid view
compile invalid view [message #656530] Mon, 10 October 2016 10:20 Go to next message
desmond30
Messages: 32
Registered: November 2009
Member

I have increased size of a column in a table, there is a view that uses this table, which is of course invalid, the strange problem i am facing is,
when I try to compile the view / or create or replace the view again, its taking a lot of time to compile,

So the question is, when a view is created (create or replace view) or when I compile an invalid view, is the sql behind the view gets executed ?
Because there is a lot of data for sure

Re: compile invalid view [message #656531 is a reply to message #656530] Mon, 10 October 2016 10:25 Go to previous messageGo to next message
Michel Cadot
Messages: 65832
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Quote:
its taking a lot of time to compile,
It should not.

Quote:
when I compile an invalid view, is the sql behind the view gets executed ?
No.

Post the definition of the view.

Re: compile invalid view [message #656532 is a reply to message #656530] Mon, 10 October 2016 10:26 Go to previous messageGo to next message
cookiemonster
Messages: 13264
Registered: September 2008
Location: Rainy Manchester
Senior Member
Unless it's a materialized view, no. All that happens is that the view is parsed to make sure it's syntactically correct and the data dictionary is updated.
Re: compile invalid view [message #656534 is a reply to message #656530] Mon, 10 October 2016 10:43 Go to previous messageGo to next message
John Watson
Messages: 7608
Registered: January 2010
Location: Global Village
Senior Member
Analyzing the data dictionary with dbms_stats.gather_dictionary_stats might help.
Re: compile invalid view [message #656535 is a reply to message #656534] Mon, 10 October 2016 12:41 Go to previous messageGo to next message
desmond30
Messages: 32
Registered: November 2009
Member
Thanks everyone, I will check and post if I find out why.

Re: compile invalid view [message #656536 is a reply to message #656535] Mon, 10 October 2016 14:47 Go to previous message
Michel Cadot
Messages: 65832
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

In the meantime you could post the view definition.

Previous Topic: If exists clause in oracle
Next Topic: rows to column text
Goto Forum:
  


Current Time: Mon Oct 15 21:07:59 CDT 2018