Record Selection by Current As of Date

  • Thread starter Thread starter KalliKay
  • Start date Start date
K

KalliKay

For Unit 100 from Property 0081, I need to find ONLY the most current As of
Date and its associated Sq Footage but my query returns ALL As of Dates and
associated Sq Footage. How can I return only the most current? Thanks.

Property Unit SF Type As of Date Sq Ft

0081 100 Rentable 12/1/1996 92246
0081 100 Rentable 12/1/2001 58387
0081 100 Rentable 5/15/2008 40345

Here is my SQL query:

SELECT
"UFPROP" AS "Property",
"UFUNIT" AS "Unit",
"UFSFTYP" AS "SF type",
"UFDATE" AS "As-of Date",
"UFSF" AS "Square footage"
FROM
"PROPERTY_PMP_RECORD_19"
Where
((UFSFTYP = 'Rentable') AND (UFUNIT = '100'))

Kalli
 
If your dates are true dates (numeric) why not try =MAX(RangeOfDate) to get the
highest number = Latest date (most current?).
 
Back
Top