This would work:
select * from tablename where datepart(year,columnname)=2003

Regards,

--
Howie Hamlin - inFusion Project Manager
On-Line Data Solutions, Inc. - www.CoolFusion.com
inFusion Mail Server (iMS) - The Award-winning, Intelligent Mail Server
PrismAV - Virus scanning for ColdFusion applications
>>> Find out how iMS Stacks up to the competition: http://www.coolfusion.com/imssecomparison.cfm

  ----- Original Message -----
  From: Michael Beveridge
  To: CF-Talk
  Sent: Wednesday, October 06, 2004 2:34 PM
  Subject: Best way to search on year

  What's the best method to do a query with dates that have the year 2003 within a date/timestamp field.
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to