<CFQUERY name="PreviousDates" datasource="calendar"> SELECT * FROM Events WHERE eDate < <CFQUERYPARAM value"=#createODBCDateTime(now())#" type="cf_sql_timestamp"> </CFQUERY>
-----Original Message----- From: Samuel R. Neff [mailto:[EMAIL PROTECTED]] Sent: Monday, January 13, 2003 10:21 AM To: CF-Talk Subject: Re: Query help! Please look at the help docs for cfqueryparam. It takes at least two params, one for value and another for type. You should specify the type. Also note that you don't have to format the date when passing to cfqueryparam. Best regards, Sam BTW, a lot of people don't use cfqueryparam until they have worked with CF for a while. I'm glad to see you're doing things the right way from the outset (that was your post about being a recent convert from ASP, right?). At 01:02 PM 1/13/2003, you wrote: >Can someone tell me what's wrong with this line: > > <CFQUERY name="PreviousDates" datasource="calendar"> > SELECT * FROM Events WHERE eDate < <CFQUERYPARAM >value=#formatdate(now(),"mm-dd-yy")#> > </CFQUERY> > >I can't figure out how to get a date query to work right... > >Thanks, > >Scott ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Signup for the Fusion Authority news alert and keep up with the latest news in ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4