I'm seeing a behavior in Rails that I find very strange. Having worked quite a bit with Oracle with other languages I would always dutifully do ALTER SESSION SET NLS_DATE_FORMAT = <my_date_format> and ensure I use that date format in my application. With Rails I still have not figured out how to execute an ALTER SESSION statement after connecting to the database (I'm using the the jdbc adapter). And sure enough I get a "date format not recognized" error when trying to save a value to a DATE column. But surprisingly when I select pre-inserted dates correctly. The default Rails date format in my platform is YYYY-MM-DD. The default date format of my Oracle database is DD-MMM-YY. Ultimately what I'm after is getting my dates to work both on select and save but I would welcome an explanation as to why Rails can select correctly with the application and the database date format being out of sync. -- Posted via http://www.ruby-forum.com/.
-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

