Re: [HACKERS] Creating temp tables inside read only transactions

Поиск
Список
Период
Сортировка
Искать
От
Jeff Davis
Тема
Re: [HACKERS] Creating temp tables inside read only transactions
Дата
Msg-id
1310225366.3012.235.camel@jdavis
Ответ на
Список
Дерево обсуждения
Creating temp tables inside read only transactions mike beeper <mbeeper@hotmail.com>
Re: Creating temp tables inside read only transactions Guillaume Lelarge <guillaume@lelarge.info>
Re: Creating temp tables inside read only transactions Darren Duncan <darren@darrenduncan.net>
Re: [HACKERS] Creating temp tables inside read only transactions Jeff Davis <pgsql@j-davis.com>
Re: [HACKERS] Creating temp tables inside read only transactions Darren Duncan <darren@darrenduncan.net>
Re: [HACKERS] Creating temp tables inside read only transactions Jeff Davis <pgsql@j-davis.com>
Re: [HACKERS] Creating temp tables inside read only transactions Darren Duncan <darren@darrenduncan.net>
Re: [HACKERS] Creating temp tables inside read only transactions Jeff Davis <pgsql@j-davis.com>
Re: [HACKERS] Creating temp tables inside read only transactions Florian Pflug <fgp@phlo.org>
Re: [HACKERS] Creating temp tables inside read only transactions Gavin Flower <GavinFlower@archidevsys.co.nz>
Re: [HACKERS] Creating temp tables inside read only transactions mike beeper <mbeeper@hotmail.com>
Re: [HACKERS] Creating temp tables inside read only transactions Robert Haas <robertmhaas@gmail.com>
Re: [HACKERS] Creating temp tables inside read only transactions Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] Creating temp tables inside read only transactions Darren Duncan <darren@darrenduncan.net>
Re: [HACKERS] Creating temp tables inside read only transactions Jeff Davis <pgsql@j-davis.com>
Re: [HACKERS] Creating temp tables inside read only transactions Darren Duncan <darren@darrenduncan.net>
Re: [HACKERS] Creating temp tables inside read only transactions Craig Ringer <craig@postnewspapers.com.au>
Re: [HACKERS] Creating temp tables inside read only transactions Darren Duncan <darren@darrenduncan.net>
Re: [HACKERS] Creating temp tables inside read only transactions Jeff Davis <pgsql@j-davis.com>
Re: [HACKERS] Creating temp tables inside read only transactions Craig Ringer <craig@postnewspapers.com.au>
Re: [HACKERS] Creating temp tables inside read only transactions Michael Nolan <htfoot@gmail.com>
Re: [HACKERS] Creating temp tables inside read only transactions John R Pierce <pierce@hogranch.com>
Re: [HACKERS] Creating temp tables inside read only transactions Christopher Browne <cbbrowne@gmail.com>
Re: [HACKERS] Creating temp tables inside read only transactions Darren Duncan <darren@darrenduncan.net>
Re: [HACKERS] Creating temp tables inside read only transactions "David Johnston" <polobo@yahoo.com>
Re: [HACKERS] Creating temp tables inside read only transactions Florian Pflug <fgp@phlo.org>
Re: [HACKERS] Creating temp tables inside read only transactions Christopher Browne <cbbrowne@gmail.com>
Re: [HACKERS] Creating temp tables inside read only transactions "David Johnston" <polobo@yahoo.com>
Re: [HACKERS] Creating temp tables inside read only transactions Darren Duncan <darren@darrenduncan.net>
Re: [HACKERS] Creating temp tables inside read only transactions Chris Travers <chris.travers@gmail.com>
Re: [HACKERS] Creating temp tables inside read only transactions Alban Hertroys <dalroi@solfertje.student.utwente.nl>
Re: [HACKERS] Creating temp tables inside read only transactions Florian Pflug <fgp@phlo.org>
On Fri, 2011-07-08 at 23:39 -0700, Darren Duncan wrote:
> What if you used the context of the calling code and resolve in favor of 
> whatever match is closest to it?  The problem is related to general-purpose 
> programming languages.
> 
> Basically start looking in the lexical context for an "x" and if you find one 
> use that; otherwise, assuming we're talking about referencing code that lives in 
> the database such as a function, look at the innermost schema containing the 
> referencing code and see if it has a direct child named "x"; otherwise go up one 
> level to a parent schema, and so on until you get to the top, and finding none 
> by then say it doesn't exist.

This is an example of where data languages and normal programming
languages have a crucial difference.

With a data language, you have this problem:
 1. An application uses a query referencing 'y.z.foo' that resolves to
internal object with fully-qualified name 'x.y.z'.
 2. An administrator creates object 'y.z.foo'.

Now, the application breaks all of a sudden.

In a normal prgramming language, if the schema of the two "foo"s are
different, the compiler could probably catch the error. SQL really has
no hope of catching it though.

PostgreSQL has this problem now in a couple ways, but it's much easier
to grasp what you might be conflicting with. If you have multiple nested
levels to traverse and different queries using different levels of
qualification, it gets a little more messy and I think a mistake is more
likely.

Regards,
	Jeff Davis

В списке pgsql-general по дате отправления
От: David Johnston
Дата:
От: Jonathan Camilleri
Дата:
FAQ