Re: Question about a query plan

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: Question about a query plan
Дата
Msg-id 20050916215102.GA29791@svana.org
обсуждение исходный текст
Ответ на Re: Question about a query plan  (Bill Moseley <moseley@hank.org>)
Список pgsql-general
On Fri, Sep 16, 2005 at 10:18:19AM -0700, Bill Moseley wrote:
> On Fri, Sep 16, 2005 at 10:02:28AM -0500, Thomas O'Connell wrote:
> > For older versions of postgres, it's recommended that you determine
> > the time in the client and use constant data in your query.
>
> Interesting.  I have a few VIEWs that include now(), but I guess I
> could adjust and pass in the date from the client.

I sometimes use the constant 'now' instead, since it obviously isn't
mutable. It's a bit tricky because sometimes it expands when you define
the statement. You have to do 'now'::text usually and even then you
should check...
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.

Вложения

В списке pgsql-general по дате отправления:

Предыдущее
От: Marc Munro
Дата:
Сообщение: Re: pg_ctl reload breaks our client
Следующее
От: Michael Fuhr
Дата:
Сообщение: Re: pg_ctl reload breaks our client