in reply to Re^2: DB Error Handling Not Working
in thread DB Error Handling Not Working

Sorry, the connection string should be DBI->connect($data_source, $username, $password, \%attr) so either use
my $dbh = DBI->connect("DBI:ODBC:$DSN",'','', {RaiseError => 1, PrintError => 1}) or die (Error connecting " $DBI::errstr");
or move the username/password out of the $DSN.
poj

Update : To get current date/time you could just use
my ($now) = $dbh->selectrow_array('SELECT CURRENT_TIMESTAMP');