| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> comp.databases.theory -> Re: Jan's well-defined view updates definition
Mikito Harakiri wrote:
> Jan Hidders <jan.hidders_at_pandora.be> wrote in message
> news:<sLq9b.22177$my3.1385515_at_phobos.telenet-ops.be>...
>> > You don't have any constraint on the base table. Therefore, >> > >> > deltaD = ( >> > update Emps >> > set dept = 'marketing' >> > where dept = 'sales' >> > ) >> > >> > is legal. >> >> Sure. But it's >> >> deltaV = ( >> update TrEmps >> set dept = 'marketing' >> where dept = 'sales' >> ) >> >> that is illegal, i.e., not well-defined. The view definition acts as a >> constraint here. There is not update that you can do on the base tables >> that would change the view in the way that is specified by deltaV.
Ah, yes, sorry. But even if the column would exist in the view then I would still consider it an illegal update.
>> Indeed. But actually I'm not transforming anything. All I do is look at >> the logical consequences of what the user has told the database. It is >> crucial that we regard the view as a set of facts and interpret updates >> as additions of deletions of facts to a certain predicate. Anything else >> would be heresy. :-)
That's one way of looking at it, and certainly a valid and interesting way to do so, but it is not the only valid point of view and certainly not how I see it. The intention of my definition was to get the most liberal notion of "updatable" that still makes sense. That doesn't mean that more restricted notions like yours don't make sense, but I would say that you would have to somehow justify your extra restriction. Since we are not just doing mathematics here but computer science it is not enough to say that the mathematics becomes more elegant.
> If some word have multiple meanings we have ambiguity, but
> typical solution in computer science is not to guess the best
> solution, right?
Could you define 'typical'? :-) I see least fixpoints all over the place. Think of the semantics of formal grammars, lambda calculus, Prolog, SQL with recursion, the definition of natural numbers, et cetera.
![]() |
![]() |