in reply to Class::DBI find_or_create
I did find out what went wrong, but I don't know whether or how to delete the question so I shall just answer it ;)
contrary to some documentation I read, one should explicitely declare the primary key, I thought it would automatically be the first ( that is what I read in the doc ) in the 'ALL' list. That is not the case. So MyDB::Foo now reads
and all is well... ;)package MyDB::Foo; use base MyDB; __PACKAGE__->table('foo'); __PACKAGE__->columns( PRIMARY =>qw/foo_id/ ); __PACKAGE__->columns( ESSENTIAL =>qw/name uri/ ); ); 1;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Class::DBI find_or_create
by choroba (Cardinal) on Dec 29, 2011 at 10:50 UTC |