1 package DBICTest::Schema::Genre;
5 use base qw/DBICTest::BaseResult/;
7 __PACKAGE__->table('genre');
8 __PACKAGE__->add_columns(
10 data_type => 'integer',
11 is_auto_increment => 1,
14 data_type => 'varchar',
18 __PACKAGE__->set_primary_key('genreid');
19 __PACKAGE__->add_unique_constraint ( genre_name => [qw/name/] );
21 __PACKAGE__->has_many (cds => 'DBICTest::Schema::CD', 'genreid');
23 __PACKAGE__->has_one (model_cd => 'DBICTest::Schema::CD', 'genreid');