=head1 SYNOPSIS
+ # In your table classes (replace PK::Auto::SQLite with your
+ # database)
+ __PACKAGE__->load_components(qw/PK::Auto::SQLite Core/);
+ __PACKAGE__->set_primary_key('id');
+
=head1 DESCRIPTION
This class overrides the insert method to get automatically
incremented primary keys.
-You don't want to be using this directly - instead load the appropriate
-one for your database, e.g. PK::Auto::SQLite
+You don't want to be using this directly - instead load the
+appropriate one for your database, e.g. C<PK::Auto::SQLite>, before
+C<Core>.
=head1 LOGIC
-PK::Auto does this by letting the database assign the primary key field
-and fetching the assigned value afterwards.
+PK::Auto does this by letting the database assign the primary key
+field and fetching the assigned value afterwards.
=head1 METHODS
\r
=head1 SYNOPSIS\r
\r
+ # In your table classes\r
+ __PACKAGE__->load_components(qw/PK::Auto::MSSQL Core/);\r
+ __PACKAGE__->set_primary_key('id');\r
+\r
=head1 DESCRIPTION\r
\r
This class implements autoincrements for MSSQL.\r
\r
You may distribute this code under the same terms as Perl itself.\r
\r
-=cut
\ No newline at end of file
+=cut\r
=head1 SYNOPSIS
+ # In your table classes
+ __PACKAGE__->load_components(qw/PK::Auto::MySQL Core/);
+ __PACKAGE__->set_primary_key('id');
+
=head1 DESCRIPTION
This class implements autoincrements for MySQL.
=head1 SYNOPSIS
+ # In your table classes
+ __PACKAGE__->load_components(qw/PK::Auto::Oracle Core/);
+ __PACKAGE__->set_primary_key('id');
+
=head1 DESCRIPTION
This class implements autoincrements for Oracle.
=head1 SYNOPSIS
+ # In your table classes
+ __PACKAGE__->load_components(qw/PK::Auto::Pg Core/);
+ __PACKAGE__->set_primary_key('id');
+
=head1 DESCRIPTION
This class implements autoincrements for Postgresql.
=head1 SYNOPSIS
+ # In your table classes
+ __PACKAGE__->load_components(qw/PK::Auto::SQLite Core/);
+ __PACKAGE__->set_primary_key('id');
+
=head1 DESCRIPTION
This class implements autoincrements for SQLite.