| From: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
|---|---|
| To: | Jan Wieck <wieck(at)debis(dot)com> |
| Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp>, pgsql-hackers(at)postgreSQL(dot)org |
| Subject: | Re: [HACKERS] SELECT FOR UPDATE leaks relation refcounts |
| Date: | 2000-02-03 12:22:11 |
| Message-ID: | 200002031222.HAA20668@candle.pha.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
> > The rewriter correctly passes SELECT FOR UPDATE locking from the
> > view to the referenced tables, but I'm not sure whether it is
> > bright enough to do the same for LOCK statements. (Jan?)
>
> Isn't LOCK TABLE a utility statement? So it doesn't go
> through the rewriter.
>
> The LOCK code would have to do the correct locking of the
> underlying tables. And not to forget cascaded views or
> possible subselects.
>
> Actually LockTableCommand() in command.c doesn't do it. It
> simply locks the view relation, what's definitely wrong.
>
Added to TODO:
* Disallow LOCK on view
--
Bruce Momjian | http://www.op.net/~candle
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Chris | 2000-02-03 12:28:31 | Re: [HACKERS] Re: [SQL] Proposed Changes to PostgreSQL |
| Previous Message | Patrick Welche | 2000-02-03 12:14:26 | Re: [HACKERS] Another nasty cache problem |