2015-07-15 15:53 GMT+02:00 Zhaomo Yang <zhy...@cs.ucsd.edu>:

> >  there is other question - what is effect of ALTER TABLE of global temp
> table on
> >  instances of this table in active sessions?
>
> As I said, we need to first agree on the behaviors of the existing
> commands. I can think of two options now for ALTER TABLE: 1) only allow
> ALTER TABLE when there is no other active sessions (this is how Oracle
> deals with it.) 2) handle it as if session copies inherit from the global
> copy and ALTER TABLE executes on the global copy.
>

There are two possible kinds of GLOBAL TEMP tables -  session related and
transation related. Transaction related tables has very short life - and @1
needs outage, @2 requires stronger locks and can slow and less effective -
because a) some changes can be invisible in other transactions (depends on
isolation levels), b) the structure can be changed, but function code not
(without dependency on isolation levels) - so it can be non consistent, c)
why to change table if this table will be dropped in next milisecond. For
this case the behave like PL functions can be very practical ~ third option
for ALTER TABLE

Regards

Pavel


> Thanks,
> Zhaomo
>

Reply via email to