Index on date_trunc

From: Christophe Labouisse <christophe(dot)labouisse(at)dial(dot)oleane(dot)com>
To: pgsql-sql(at)postgreSQL(dot)org
Subject: Index on date_trunc
Date: 1999-04-22 20:21:49
Message-ID: m3r9pcbe3m.fsf@gabuzo.meunet
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

I'm trying to index on a part of a datetime field. I tried the
following statement :

create index ns_dt1_idx on netstats (date_trunc('day',NS_DATE) datetime_ops);

It doesn't work and I get :

ERROR: parser: parse error at or near "'"

Any idea ?

--
Christophe Labouisse : Cinéma, typographie, Unix
christophe(dot)labouisse(at)dial(dot)oleane(dot)com http://www.multimania.com/gabuzo/
Le cinéma en Lumière : http://www.lumiere.org/

Browse pgsql-sql by date

  From Date Subject
Next Message JT Kirkpatrick 1999-04-22 20:32:23 backend closing channel unexpectedly
Previous Message Justin Long 1999-04-22 18:52:34 SELECT TOP X -- part 2 -- parse error?