From: Joseph Shraibman <jks@selectacast.net>
To: pgsql-sql@postgresql.org <pgsql-sql@postgresql.org>
Subject: select by streak
Date: Wed, 20 Jun 2001 15:35:38 -0400
Message-ID: <3B30FB0A.3595CD79@selectacast.net> (raw)
Lets say I have a table like this:
id int <== primary key
ts timestamp
name text
status char
status is G for good or B for bad. How do I do something like:
SELECT name FROM mytable WHERE <last 3 entires in a row have status =
'B'> and <has been no good ones in the past week> ?
--
Joseph Shraibman
jks@selectacast.net
Increase signal to noise ratio. http://www.targabot.com
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 using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: jks@selectacast.net
Subject: Re: select by streak
In-Reply-To: <3B30FB0A.3595CD79@selectacast.net>
* 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