<CFQuery = "q_results>
SELECT Top 1 * FROM T_EMAIL
ORDER BY Eid DESC
</CFQUERY>

-----Original Message-----
From: Mark Leder [mailto:[EMAIL PROTECTED]]
Sent: Sunday, January 20, 2002 5:36 PM
To: CF-Talk
Subject: Retrieving most recent record from db


How to I write a CFquery statement to retrieve the most recent record 
from
an record ID (primary key)?

In other words,

<CFQuery = "q_results>
SELECT * FROM T_EMAIL
where Eid = (this is where the most recent statement would go, I 
think)
</CFQUERY>

Thanks in advance for your help.

Mark

______________________________________________________________________
Why Share?
  Dedicated Win 2000 Server � PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
  Instant Activation � $99/Month � Free Setup
  http://www.pennyhost.com/redirect.cfm?adcode=coldfusionc
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to