Commit | Line | Data |
843f8ecd |
1 | package DBIx::Class::Storage::DBI::mysql; |
2 | |
3 | use strict; |
4 | use warnings; |
5 | |
6 | use base qw/DBIx::Class::Storage::DBI/; |
7 | |
8 | # __PACKAGE__->load_components(qw/PK::Auto/); |
9 | |
10 | sub last_insert_id { |
a9f32dbc |
11 | return shift->dbh_do(sub { shift->{mysql_insertid} } ); |
843f8ecd |
12 | } |
13 | |
e8d293df |
14 | sub sqlt_type { |
15 | return 'MySQL'; |
16 | } |
17 | |
843f8ecd |
18 | 1; |
19 | |
75d07914 |
20 | =head1 NAME |
843f8ecd |
21 | |
22 | DBIx::Class::Storage::DBI::mysql - Automatic primary key class for MySQL |
23 | |
24 | =head1 SYNOPSIS |
25 | |
26 | # In your table classes |
27 | __PACKAGE__->load_components(qw/PK::Auto Core/); |
28 | __PACKAGE__->set_primary_key('id'); |
29 | |
30 | =head1 DESCRIPTION |
31 | |
32 | This class implements autoincrements for MySQL. |
33 | |
34 | =head1 AUTHORS |
35 | |
36 | Matt S. Trout <mst@shadowcatsystems.co.uk> |
37 | |
38 | =head1 LICENSE |
39 | |
40 | You may distribute this code under the same terms as Perl itself. |
41 | |
42 | =cut |