Is there a way to have a formfield of european date formatted text be stored as such, so it outputs in the sameformat? When I output it from the database it's reversing the month and day back to US standard.
since almost every database stores dates as integer numbers, the choice of which format to display it in is usually a settable default in the database, plus, you can use formatting functions in the sql(e.g. FORMAT() in access, CONVERT() in sql server, TO_CHAR in oracle), or, alternatively, if you choose to return an actual date object in the result set, you can then use coldfusion's
DateFormat function
but, to recap, dates are not stored in any particular format, they are stored as the number of days since january 1, 1573, or some such (depends on the database)
Thank you for the info. I don't know the syntax for the CONVERT() function, but the date format in CF works all the same. Just wanted to make sure I wasn't missing any crucial information.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.