Commit | Line | Data |
8273e845 |
1 | package # hide from PAUSE |
c6d74d3e |
2 | DBICTest::Schema::FourKeys; |
a02675cd |
3 | |
4a233f30 |
4 | use warnings; |
5 | use strict; |
6 | |
660cf1be |
7 | use base qw/DBICTest::BaseResult/; |
a02675cd |
8 | |
11357d09 |
9 | __PACKAGE__->table('fourkeys'); |
10 | __PACKAGE__->add_columns( |
0009fa49 |
11 | 'foo' => { data_type => 'integer' }, |
12 | 'bar' => { data_type => 'integer' }, |
13 | 'hello' => { data_type => 'integer' }, |
14 | 'goodbye' => { data_type => 'integer' }, |
ff1234ad |
15 | 'sensors' => { data_type => 'character', size => 10 }, |
0e773352 |
16 | 'read_count' => { data_type => 'int', is_nullable => 1 }, |
0009fa49 |
17 | ); |
11357d09 |
18 | __PACKAGE__->set_primary_key(qw/foo bar hello goodbye/); |
a02675cd |
19 | |
11357d09 |
20 | __PACKAGE__->has_many( |
256e87b0 |
21 | 'fourkeys_to_twokeys', 'DBICTest::Schema::FourKeys_to_TwoKeys', { |
3bd6e3e0 |
22 | 'foreign.f_foo' => 'self.foo', |
23 | 'foreign.f_bar' => 'self.bar', |
24 | 'foreign.f_hello' => 'self.hello', |
25 | 'foreign.f_goodbye' => 'self.goodbye', |
26 | }); |
27 | |
11357d09 |
28 | __PACKAGE__->many_to_many( |
3bd6e3e0 |
29 | 'twokeys', 'fourkeys_to_twokeys', 'twokeys', |
30 | ); |
31 | |
a02675cd |
32 | 1; |