Skip site navigation (1) Skip section navigation (2)

Re: How to query for Interval

From: Richard Broersma Jr <rabroersma(at)yahoo(dot)com>
To: Vishal Kashyap <vishalonlist(at)gmail(dot)com>, PostgreSQL Novice <pgsql-novice(at)postgresql(dot)org>
Subject: Re: How to query for Interval
Date: 2006-04-11 21:26:24
Message-ID: 20060411212624.84671.qmail@web31811.mail.mud.yahoo.com (view raw or flat)
Thread:
Lists: pgsql-novice
This thread might be useful to you also.

http://archives.postgresql.org/pgsql-sql/2006-04/msg00014.php

Regards,

Richard

--- Vishal Kashyap  <vishalonlist(at)gmail(dot)com> wrote:

> Hi,
> 
> 
> I have a table with time stamps in it . These timestamp represent a event count.
> I just wanted to know how could I query such that I get a count of
> event per hour.
> 
> Table structure is
> 
> my_table(id serial, time_event timestamp,event varchar(200));
> 
> I want to do something like
> select count(id) from  my_table where time_event in (every 1 hour);
> 
> Any pointers / help would be appreciated
> 
> 
> --
> With Best Regards,
> Vishal Kashyap.
> http://www.vishal.net.in
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 1: if posting/reading through Usenet, please send an appropriate
>        subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
>        message can get through to the mailing list cleanly
> 


In response to

pgsql-novice by date

Next:From: Andre MajorelDate: 2006-04-11 22:13:04
Subject: Re: Curses interface
Previous:From: Richard Broersma JrDate: 2006-04-11 21:16:55
Subject: Re: How to query for Interval

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group