Convert them to dates.

On the SQL side use the convert() function, on the CF side use the
CreateODBCDate() fucntion.

Russ 

-----Original Message-----
From: Cornel Ivanescu [mailto:[EMAIL PROTECTED] 
Sent: 04 November 2006 18:40
To: CF-Talk
Subject: Re: Where Date Statement in MySQL

I actually got it to stop giving me an error by putting the first Left
stateement in between quotes, however it does not compare them as dates but
strings...I saw that once the error stopped showing up...
How do I change it so MySQL does compare them as dates? as that was the
original intent.

Cornel


>First, use CFQUERYPARAM with CF_SQL_VARCHAR as the type.  There are 
>various security/performance reasons, but it will also prevent MySQL 
>from doing an implict conversion to a date.  I don't know if it's 
>happening, but it might be.  Also consider that you're doing string 
>comparisons, not date comparisons, so things might not be quite as 
>you'd expect.
>
>cheers,
>barneyb
>
>On 11/4/06, Cornel Ivanescu <[EMAIL PROTECTED]> wrote:
>>



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four 
times a year.
http://www.fusionauthority.com/quarterly

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:259175
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to