view puzzle

From: <puppet_sock_at_hotmail.com>
Date: 16 Jan 2004 07:57:59 -0800
Message-ID: <c7976c46.0401160757.5ac25579_at_posting.google.com>


Here's what I want to do.

I want a view that restricts to rows that are "in date" when a working date exists, but shows the whole table when no date exists.

I have a temporary global work-items table that has a single row including the working date as one column. This is scrubbed when the connetion to the database is closed. But some automated processes will connect and not put an entry into the work items table. There will be zero rows in the table.

Is there a not-too-complicated way to construct a view that restricts by a date when there is one, but does not restrict when there is no date?

Restricting to the date is pretty simple when it's there. It's just a select statement that has start_date <= working_date and end_date >= working_date. But how do I procede when there is no working date?
Socks Received on Fri Jan 16 2004 - 16:57:59 CET

Original text of this message