Merge 'trunk' into 'DBIx-Class-current'
[dbsrgits/DBIx-Class.git] / t / lib / DBICTest / Schema / TwoKeyTreeLike.pm
CommitLineData
637ca936 1package # hide from PAUSE
2 DBICTest::Schema::TwoKeyTreeLike;
3
4use base qw/DBIx::Class/;
5
6__PACKAGE__->load_components(qw/Core/);
7
8__PACKAGE__->table('twokeytreelike');
9__PACKAGE__->add_columns(
10 'id1' => { data_type => 'integer' },
11 'id2' => { data_type => 'integer' },
12 'parent1' => { data_type => 'integer' },
13 'parent2' => { data_type => 'integer' },
14 'name' => { data_type => 'varchar',
15 size => 100,
16 },
17);
18__PACKAGE__->set_primary_key(qw/id1 id2/);
19__PACKAGE__->belongs_to('parent', 'TwoKeyTreeLike',
20 { 'foreign.id1' => 'self.parent1', 'foreign.id2' => 'self.parent2'});
21
221;