pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Indexing Timestamp Data
2+ messages / 2 participants
[nested] [flat]

* Indexing Timestamp Data
@ 1998-05-15 16:07  Romualdo Alves <romualdo@crn.inpe.br>
  0 siblings, 0 replies; 2+ messages in thread

From: Romualdo Alves @ 1998-05-15 16:07 UTC (permalink / raw)
  To: pgsql-sql

	How to index a timestamp data in a Postgres table?

	For example, I tried: CREATE UNIQUE INDEX idx ON table_01 (xtime);
The resulting message was: "CAN'T FIND A DEFAULT OPERATOR CLASS FOR TYPE
1296".

	The table 'table_01' was created with the following command:
CREATE TABLE table_01 (
             xtime TIMESTAMP,
             code  CHAR(5),
             qty   INTEGER);

	The key of this table must be the 'xtime' field which is of TIMESTAMP data
type. How to do it?


	Romualdo.


------------------------------------------------------------
My ICQ# 10480879
My Home Page: http://wwp.mirabilis.com/10480879 
My E-mail Express: 10480879@pager.mirabilis.com
INPE Telephone Number: (084) 231-4733 Ext. 214

"For we are labourers together with God" (1 Corinthians 3:9)
"De Deus somos cooperadores"             (1 Corintios 3:9)
------------------------------------------------------------



^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* RE: [SQL] Indexing Timestamp Data
@ 1998-05-15 20:34  Jackson, DeJuan <djackson@cpsgroup.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Jackson, DeJuan @ 1998-05-15 20:34 UTC (permalink / raw)
  To: Romualdo Alves <romualdo@crn.inpe.br>; pgsql-sql

Just as a suggestion you might want to use DATETIME instead of
TIMESTAMP.

> 	How to index a timestamp data in a Postgres table?
> 
> 	For example, I tried: CREATE UNIQUE INDEX idx ON table_01
> (xtime);
> The resulting message was: "CAN'T FIND A DEFAULT OPERATOR CLASS FOR
> TYPE
> 1296".
> 
> 	The table 'table_01' was created with the following command:
> CREATE TABLE table_01 (
>              xtime TIMESTAMP,
>              code  CHAR(5),
>              qty   INTEGER);
> 
> 	The key of this table must be the 'xtime' field which is of
> TIMESTAMP data
> type. How to do it?
> 
> 
> 	Romualdo.
> 
> 
> ------------------------------------------------------------
> My ICQ# 10480879
> My Home Page: http://wwp.mirabilis.com/10480879 
> My E-mail Express: 10480879@pager.mirabilis.com
> INPE Telephone Number: (084) 231-4733 Ext. 214
> 
> "For we are labourers together with God" (1 Corinthians 3:9)
> "De Deus somos cooperadores"             (1 Corintios 3:9)
> ------------------------------------------------------------



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~1998-05-15 20:34 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
1998-05-15 16:07 Indexing Timestamp Data Romualdo Alves <romualdo@crn.inpe.br>
1998-05-15 20:34 RE: [SQL] Indexing Timestamp Data Jackson, DeJuan <djackson@cpsgroup.com>

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