Hi all.

The SQL Server docs say that you can instruct SQL Server to interpret
dates in the format you want ( for example in insert statements ) by
issuing the command:

set dateformat xxx

where xxx is the format string, for example dmy

So I'm doing:

my $sth = $dbh->prepate( "set dateformat dmy" );
$sth->execute || die $dbh->errstr;
$sth->finish;

This code runs without error, but doesn't seem to affect the way SQL
Server interprets dates that I give it. ie I'm still getting stuff like:

DBD::ODBC::st execute failed: [unixODBC][FreeTDS][SQL Server]The
conversion of a char data type to a datetime data type resulted in an
out-of-range datetime value.

What am I doing wrong?

-- 
Daniel Kasak
IT Developer
NUS Consulting Group
Level 5, 77 Pacific Highway
North Sydney, NSW, Australia 2060
T: (+61) 2 9922-7676 / F: (+61) 2 9922 7989
email: [EMAIL PROTECTED]
website: http://www.nusconsulting.com.au

Reply via email to