pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: ww zz <ts_999@yahoo.com>
To: pgsql-sql@postgresql.org
Subject: how to do this query?
Date: Tue, 20 May 2003 09:00:11 -0700 (PDT)
Message-ID: <20030520160011.81254.qmail@web41803.mail.yahoo.com> (raw)

New to sql and may be a simple question for you:

I have four tables

sample:   sid, sname
make:     sid, mdate
measure:  sid, mdate, rid
result:   rid, resultdata

for a gaven sample it always has a sid and sname, but
it may or may not have any entries in the other
tables, the sample could be measured more than once
and each measure give a result row.
question:
how do I do a query that given a sid, it will retrieve
all the information available in the four tables, if
there are available. If, for example, all tables have
some entry for a gave sample it will retreve all the
information, if the "measure" and "result" are empty
for that sample it will give only the 'sample' and
'make' information....

please help

Thanks



__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com



view thread (9+ messages)  latest in thread

Message-ID: <20030520160011.81254.qmail@web41803.mail.yahoo.com>
Permalink:  ../20030520160011.81254.qmail@web41803.mail.yahoo.com/
Also on:    postgresql.org/message-id/20030520160011.81254.qmail@web41803.mail.yahoo.com

 · 

reply

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: ts_999@yahoo.com
  Subject: Re: how to do this query?
  In-Reply-To: <20030520160011.81254.qmail@web41803.mail.yahoo.com>

* 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