Re: dateformat issue - Mailing list pgsql-sql

From Aarni Ruuhimäki
Subject Re: dateformat issue
Date
Msg-id 200804101027.24977.aarni@kymi.com
Whole thread Raw
In response to Re: dateformat issue  (Gavin 'Beau' Baumanis <gavinb@eclinic.com.au>)
List pgsql-sql
On Thursday 10 April 2008 09:41, Gavin 'Beau' Baumanis wrote:
> Hi Aarni,
>
> just so you know I am using the CF built-in function,
> createodbcdate
>
> here is the info from livedocs.
>
> CreateODBCDate
> Description
>
> Returns a date in ODBC date format.
> Category
>
> Date and time functions
> Syntax
>
> CreateODBCDate(date)
>
> so I pass in 2008-01-23
> and I get back
>
> {d '2008-01-23'}
>
> The weirdness for me is that it works elsewhere in the application, I
> am really stumped.
>
> -Gavin.
>

That value shouldn't work at all ... ?

<cfoutput>
#Now()# ||

#CreateODBCDate(2008-04-10)# = #CreateODBCDate(1994)#

|
#CreateODBCDate('2008-04-10')#
|
#CreateODBCDate(Now())#
|
#DateFormat(Now(), "YYYY-MM-DD")#
|
#DateFormat('2008-04-10', "YYYY-MM-DD")#
</cfoutput>

Produces:
{ts '2008-04-10 10:26:21'} || {d '1905-06-16'} = {d '1905-06-16'} | {d
'2008-04-10'} | {d '2008-04-10'} | 2008-04-10 | 2008-04-10

This is on CFMX7.

Best regards,

--
Aarni Ruuhimäki
---
Burglars usually come in through your windows.
---


pgsql-sql by date:

Previous
From: Gavin 'Beau' Baumanis
Date:
Subject: Re: dateformat issue
Next
From: Tk421
Date:
Subject: Re: dateformat issue