1 package DBIx::Class::Storage::DBI::MSSQL;
6 use base qw/DBIx::Class::Storage::DBI/;
8 # __PACKAGE__->load_components(qw/PK::Auto/);
11 my( $id ) = $_[0]->_dbh->selectrow_array('SELECT @@IDENTITY' );
15 sub build_datetime_parser {
17 my $type = "DateTime::Format::Strptime";
19 $self->throw_exception("Couldn't load ${type}: $@") if $@;
20 return $type->new( pattern => '%m/%d/%Y %H:%M:%S' );
27 DBIx::Class::Storage::DBI::MSSQL - Automatic primary key class for MSSQL
31 # In your table classes
32 __PACKAGE__->load_components(qw/PK::Auto Core/);
33 __PACKAGE__->set_primary_key('id');
37 This class implements autoincrements for MSSQL.
41 Brian Cassidy <bricas@cpan.org>
45 You may distribute this code under the same terms as Perl itself.