Need Help Getting earliest date

L

Laura1

I have a table set up like this:

Account# Date Open Date Referred

12345 12/30/2006 12/1/2006
12345 1/20/2006 12/1/2006
12345 5/30/2007 12/1/2006

I need a querry to tell the earliest date. If the date referred is early
then the account open date then give me that for all the accounts. If the
account open date is earlier then the date referred then give me that. Any
ideas?

I am stuck.

Thank you!!
 
P

Priustoric

I think using an Iif function would work well. Put something like this
in a new field in the query:

dtEarliest: IIf([Date Open]<[Date Referred],[Date Open],[Date
Referred])

Hope that helps.
 
L

Laura1

Thank you so very much it worked!!! You saved me hours of playing!!! A+++++
I think using an Iif function would work well. Put something like this
in a new field in the query:

dtEarliest: IIf([Date Open]<[Date Referred],[Date Open],[Date
Referred])

Hope that helps.
I have a table set up like this:
[quoted text clipped - 12 lines]
Thank you!!
 

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

Similar Threads

Determining earliest date 2
Date Diff Function 2
Combining records by date 1
Query Help 5
Help! 1
Excel DateDif - why does 2007 seem different? 3
5 minute time increments 2
Function to return earliest date 0

Top