Received: from maynard.mail.mindspring.net (maynard.mail.mindspring.net [207.69.200.243]) by mail.postgresql.org (8.11.3/8.11.1) with ESMTP id f2LD8Et82128 for ; Wed, 21 Mar 2001 08:08:14 -0500 (EST) (envelope-from bcdoyle@mindspring.com) Received: from hbg-ntd-467b.mindspring.com (fw-1.hbg2.fw.mindspring.net [199.174.119.5]) by maynard.mail.mindspring.net (8.9.3/8.8.5) with ESMTP id IAA13040 for ; Wed, 21 Mar 2001 08:08:09 -0500 (EST) Message-Id: <5.0.2.1.2.20010321080320.02f98360@pop.internal.mindspring.com> X-Sender: bcdoyle@pop.internal.mindspring.com X-Mailer: QUALCOMM Windows Eudora Version 5.0.2 Date: Wed, 21 Mar 2001 08:07:56 -0500 To: pgsql-sql@postgresql.org From: "Brian C. Doyle" Subject: Complex Query Help Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-Archive-Number: 200103/413 X-Sequence-Number: 2081 Hello all, I have a table of work shifts. It has Table "teams" Attribute | Type | Modifier ------------+---------------+---------- team_id | varchar(50) | team_name | varchar(100) | location | varchar(100) | department | varchar(100) | shift | varchar(100) | start_time | numeric(30,6) | end_time | numeric(30,6) | mon | boolean | tue | boolean | wen | boolean | thu | boolean | fri | boolean | sat | boolean | sun | boolean | start_day | char(3) | end_day | char(3) | What I need to be able to do is select team_name where team works between a time span ie teams that work between 730 and 1600 how would I do this???? What type of field should i sue for start_time and end_time?