From: Tom Lane <tgl@sss.pgh.pa.us>
To: Gaetano Mendola <mendola@bigfoot.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: date is not immutable ?
Date: Wed, 12 Mar 2003 16:46:58 -0500
Message-ID: <29517.1047505618@sss.pgh.pa.us> (raw)
In-Reply-To: <b4labj$15lq$1@news.hub.org>
References: <b4labj$15lq$1@news.hub.org>
"Gaetano Mendola" <mendola@bigfoot.com> writes:
> I'm trying to create an index on a timestamptz field just extracting the
> date:
> # create index idx_user_logs_login_time_date on user_logs (
> date(login_time) );
> ERROR: DefineIndex: index function must be marked IMMUTABLE
> why date is not marked immutable ?
Because the conversion depends on your timezone setting.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: tgl@sss.pgh.pa.us, mendola@bigfoot.com
Subject: Re: date is not immutable ?
In-Reply-To: <29517.1047505618@sss.pgh.pa.us>
References: <b4labj$15lq$1@news.hub.org> <29517.1047505618@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox