Received: from localhost (unknown [200.46.204.183]) by developer.postgresql.org (Postfix) with ESMTP id 9B07D2E0055 for ; Thu, 10 Apr 2008 04:27:38 -0300 (ADT) Received: from developer.postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 02132-02 for ; Thu, 10 Apr 2008 04:27:35 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from smtp10.kymp.net (smtp10.kymp.net [80.248.96.136]) by developer.postgresql.org (Postfix) with ESMTP id 997D02E004E for ; Thu, 10 Apr 2008 04:27:34 -0300 (ADT) Received: from kymifedora ([213.130.241.66]) by smtp10.kymp.net (8.13.6/8.13.6) with ESMTP id m3A7RPRE032727; Thu, 10 Apr 2008 10:27:25 +0300 From: Aarni =?iso-8859-1?q?Ruuhim=E4ki?= Reply-To: aarni@kymi.com Organization: KYMI.com To: pgsql-sql@postgresql.org Subject: Re: dateformat issue Date: Thu, 10 Apr 2008 10:27:24 +0300 User-Agent: KMail/1.6.2 References: <8817FD2B-5B01-4E3D-9C6D-A6FF165561FB@eclinic.com.au> <200804100917.33729.aarni@kymi.com> In-Reply-To: Cc: "Gavin 'Beau' Baumanis" MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Message-Id: <200804101027.24977.aarni@kymi.com> X-Virus-Scanned: by amavisd-new X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200804/64 X-Sequence-Number: 30603 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 ... ? =20 =20 #Now()# || #CreateODBCDate(2008-04-10)# =3D #CreateODBCDate(1994)# |=20 =20 #CreateODBCDate('2008-04-10')#=20 =20 |=20 =20 #CreateODBCDate(Now())#=20 =20 |=20 =20 #DateFormat(Now(), "YYYY-MM-DD")#=20 =20 |=20 =20 #DateFormat('2008-04-10', "YYYY-MM-DD")#=20 Produces: {ts '2008-04-10 10:26:21'} || {d '1905-06-16'} =3D {d '1905-06-16'} | {d=20 '2008-04-10'} | {d '2008-04-10'} | 2008-04-10 | 2008-04-10 This is on CFMX7. Best regards, =2D-=20 Aarni Ruuhim=E4ki =2D-- Burglars usually come in through your windows. =2D--