Re: First day of month, last day of month - Mailing list pgsql-sql

From Scott Marlowe
Subject Re: First day of month, last day of month
Date
Msg-id dcc563d10804240816v58322af0jaeb6d3a0b58967f2@mail.gmail.com
Whole thread Raw
In response to Re: First day of month, last day of month  ("Fernando Hevia" <fhevia@ip-tel.com.ar>)
Responses Re: First day of month, last day of month  ("Scott Marlowe" <scott.marlowe@gmail.com>)
List pgsql-sql
On Thu, Apr 24, 2008 at 9:10 AM, Fernando Hevia <fhevia@ip-tel.com.ar> wrote:
>  > De: pgsql-sql-owner@postgresql.org
>  > [mailto:pgsql-sql-owner@postgresql.org] En nombre de Scott Marlowe
>
> >
>  > Then you can just use date_trunc on the values in the
>  > database. Plus if you're using timestamp WITHOUT timezone,
>  > you can index on it.
>  >
>
>  Did not understand this. Are you saying timestamps WITH timezone are NOT
>  indexable or you mean that you cant build a partial index on a
>  timestamp-with-time-zone returning function?

Correct, timestamptz or timestamp with timezone (timestamptz is the
shorter alias) are not indexable because functions in an index must be
immutable, and date_trunc on a timestamptz is not.


pgsql-sql by date:

Previous
From: Erik Jones
Date:
Subject: Re: First day of month, last day of month
Next
From: TJ O'Donnell
Date:
Subject: Re: How I can check a substring is a valid number in postgresql ?