Need help with Date range query

G

Guest

Hey guys,

I sure hope that this question is not seen as to elementary. I am attempting
to create a data base that keeps track of residents admitted to a hospice
unit, what I need is to be able to find out how many residents where on the
hospice unit every day by using the admission date through their discharge
date, if they are current I am using Date () in the discharge date field and
I need to do this using a start date from the time the unit opened over a
year ago. I hope this is enough information and that it is understandable. If
anyone can help or needs more information please leave a response I will
check back often.
 
D

Douglas J. Steele

For any given date, you can retrieve the number of residents using

WHERE AdmissionDate <= Date() AND DischargeDate >= Date()
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top