From: Gavin Sinclair Date: 2002-10-19T17:15:13+09:00 Subject: Re: Date handling with DBI From: "ahoward" > > > > > stm = dbh.prepare("intert into test values (?)") > > > stm.execute(Time.now) > > > > > > -billy. > > > > I tried that code and got the following error: > > > > ../site_ruby/1.6/DBD/Oracle/Oracle.rb:290:in `execute': ORA-01861: literal > > does not match format string (DBI::DatabaseError) > > > > I guess the driver's just not built for it :( > > silly question, but have you tried quoting the date string? > > stm = dbh.prepare("insert into test values ('?')") > > > i have not used the dbi, or oracle, but i need the quote the output of > Time.now when i use it in postgresql - so i thought i'd throw that out > there... > Thanks 'a' :) I'll try that at work on Monday. It seems like a good idea. I can't predict whether it will work, though... Gavin