DBIx-Class - Error messages not thrown for insert update connect failures

Posted on Fri Jan 25 15:48:30 2008 by slj
Error messages not thrown for insert update connect failures
Hi, We just upgraded from on older version of DBIx to the latest version. The latest version doesn't throw proper error messages when insert/update/connect fails. This is the sample code that I run
my $user = $db->resultset('User')->create({id => 'slj', email => 'slj@yahoo.com'});
The code should throw a unique constraint violation but this is what I get
$ ./get_user.pl Can't call method "resolve" on an undefined value at /usr/local/perl/5.8.7/lib/DBIx/Class/Row.pm li +ne 707.
The same code gave the follwing error with older version of DBIx.
$ ~/prog/get_user.pl DBD::ODBC::st execute failed: [unixODBC][TimesTen][TimesTen 7.0.1.0.0 ODBC Driver][TimesTen]TT0907: + Unique constraint (TTUNIQUE_34) violated at Rowid <0x018d19ac> -- file "ttree.c", lineno 4077, pr +ocedure "sbTtInsert" (SQL-23000)(DBD: st_execute/SQLExecute err=-1) at /usr/local/perl/5.8.7/lib/D +BIx/Class/Storage/DBI.pm line 771. DBIx::Class::PK::Auto::insert(): Error executing 'INSERT INTO users (email, id) VALUES (?, ?, )': [ +unixODBC][TimesTen][TimesTen 7.0.1.0.0 ODBC Driver][TimesTen]TT0907: Unique constraint (TTUNIQUE_3 +4) violated at Rowid <0x018d19ac> -- file "ttree.c", lineno 4077, procedure "sbTtInsert" (SQL-2300 +0)(DBD: st_execute/SQLExecute err=-1) ....
Has anyone faced this issue? Is this a bug with DBIx or I am missing something? Could someone help on this? Thanks, Libitha
Direct Responses: 7882 | 7910 | Write a response