in reply to MySQL and PERL tribulations....

better way is:
$sth = $dbh->prepare($query) or die "DB Error: ".$dbh->errstr."\n";
at every database execution. After that you should examine the error code in error.log, or where errors are written.

It can be so much thing, that we have to have a look at that first. (e.g. different database table format, etc)

Tip: besides your method fill up date and time fields with mysql now() function - if it is mysql - or with CURRENT_TIMESTAMP variable. They also work with Postgres.

cheers

-- tune

Replies are listed 'Best First'.
RE: Re: MySQL and PERL tribulations....
by agoth (Chaplain) on Nov 08, 2000 at 15:23 UTC
    Why is your way a better way to do the errors?
    type or die on each statement? or use RaiseError that he correctly did in the first place and save all the typing and get the errors anyway?