Re: [GENERAL] Rewriting select statements

2009-11-02 Thread Raymond O'Donnell
On 02/11/2009 19:47, Vick Khera wrote: > On Sat, Oct 31, 2009 at 1:06 AM, David Fetter wrote: >>> I fully agree that it's broken, but my users just see the delay. I >>> might have to try some sort of proxy arrangement. >> This is not your problem. Treating it as though it were your problem >> wi

Re: [GENERAL] Rewriting select statements

2009-11-02 Thread Vick Khera
On Sat, Oct 31, 2009 at 1:06 AM, David Fetter wrote: >> I fully agree that it's broken, but my users just see the delay.  I >> might have to try some sort of proxy arrangement. > > This is not your problem.  Treating it as though it were your problem > will only lead to enormous pain to you, and w

Re: [GENERAL] Rewriting select statements

2009-10-30 Thread David Fetter
On Sat, Oct 31, 2009 at 08:57:03AM +1100, Phil Cairns wrote: > Tom Lane wrote: > > "Phil Cairns" writes: > > > I want to have the server do this: If the query has no where > > > clause, use a where clause of "where 1=0". > > > > > Is this possible? > > > > It's doubtless *possible*, but if you'r

Re: [GENERAL] Rewriting select statements

2009-10-30 Thread Scott Marlowe
Oh, nevermind, read the thread again. On Fri, Oct 30, 2009 at 5:40 PM, Scott Marlowe wrote: > On Fri, Oct 30, 2009 at 3:57 PM, Phil Cairns wrote: >> Tom Lane wrote: >>> Tell the library authors to fix their broken code.  This is blithering >>> stupidity in *any* SQL database, not only Postgres.

Re: [GENERAL] Rewriting select statements

2009-10-30 Thread Scott Marlowe
On Fri, Oct 30, 2009 at 3:57 PM, Phil Cairns wrote: > Tom Lane wrote: >> Tell the library authors to fix their broken code.  This is blithering >> stupidity in *any* SQL database, not only Postgres. > > Tried that, and got no response. I fully agree that it's broken, but my > users just see the de

Re: [GENERAL] Rewriting select statements

2009-10-30 Thread Scott Marlowe
On Fri, Oct 30, 2009 at 2:07 PM, Phil Cairns wrote: > I want to have the server do this: > > If the query has no where clause, use a where clause of "where 1=0". > > Is this possible? Anyway to add a 'limit 1' to the end of the query somewhere on the app side? Like Tom said, this app sounds reta

Re: [GENERAL] Rewriting select statements

2009-10-30 Thread Phil Cairns
Tom Lane wrote: > "Phil Cairns" writes: > > I want to have the server do this: > > If the query has no where clause, use a where clause of "where 1=0". > > > Is this possible? > > It's doubtless *possible*, but if you're asking for it to actually > happen in any supported version of Postgres, th

Re: [GENERAL] Rewriting select statements

2009-10-30 Thread Tom Lane
"Phil Cairns" writes: > I want to have the server do this: > If the query has no where clause, use a where clause of "where 1=0". > Is this possible? It's doubtless *possible*, but if you're asking for it to actually happen in any supported version of Postgres, the answer is no way. It's direct

[GENERAL] Rewriting select statements

2009-10-30 Thread Phil Cairns
I want to have the server do this: If the query has no where clause, use a where clause of "where 1=0". Is this possible? Why would I want to do this? Because a third party library (ArcGIS) has a "feature" such that when a relation name is registered with it, it does a "select * from " and then