Mercurial > pub > Impl
annotate Lib/IMPL/SQL/Schema/Constraint/Index.pm @ 167:1f7a6d762394
SQL schema in progress
author | sourcer |
---|---|
date | Thu, 12 May 2011 08:57:19 +0400 |
parents | 76515373dac0 |
children | 6148f89bb7bf |
rev | line source |
---|---|
49 | 1 package IMPL::SQL::Schema::Constraint::Index; |
2 use strict; | |
165 | 3 use parent qw(IMPL::SQL::Schema::Constraint); |
49 | 4 |
5 __PACKAGE__->PassThroughArgs; | |
6 | |
7 sub CTOR { | |
8 my $this = shift; | |
9 | |
10 my %colnames; | |
165 | 11 not grep { $colnames{$_}++ } @{$this->columns} or die new Exception('Each column in the index can occur only once'); |
49 | 12 } |
13 | |
14 1; |