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

Home -> Community -> Usenet -> c.d.o.server -> Re: Using Packages makes ALTER TABLE dangerous

Re: Using Packages makes ALTER TABLE dangerous

From: Frank <fbortel_at_nescape.net>
Date: Mon, 08 Dec 2003 22:43:28 +0100
Message-ID: <br2qph$9u3$1@news4.tilbu1.nb.home.nl>


Joachim Zobel wrote:

> Hi.
>
> Today the following happened:
> When recreating several tables on friday afternoon I had forgotten a
> DEFAULT. I noticed this while checking the error logs this morning and
> then did the ALTER TABLE to set the DEFAULT. This was a mistake.
>
> All write access to this table goes through a package. When I ALTERed the
> table, this package got invalid. Unfortunately there where active sessions
> using the package, which in fact where idly hanging around due to bad
> application error handling. So the package could not be compiled and all
> write access to the table was blocked.
>
> Several questions arise:
> Will this behaviour improve with oracle 9 (we are using 8.1.7)? Is there a
> way to use packages for table encapsulation and still be able to do ALTER
> TABLEs without fear?
>
> Thanx,
> Joachim
>

No - there's a dependency between the package and the table. If one of the dependants changes, the objects depending get invalidated. And when using encapsulation, how can you alter the table? Surely this should be solved withing the package...

-- 
Regards, Frank van Bortel
Received on Mon Dec 08 2003 - 15:43:28 CST

Original text of this message

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