1DBIx::Class::Storage::DUBsIe:r:PCgo(n3t)ributed Perl DocDuBmIexn:t:aCtliaosns::Storage::DBI::Pg(3)
2
3
4
6 DBIx::Class::Storage::DBI::Pg - Automatic primary key class for
7 PostgreSQL
8
10 # In your result (table) classes
11 use base 'DBIx::Class::Core';
12 __PACKAGE__->set_primary_key('id');
13
15 This class implements autoincrements for PostgreSQL.
16
18 This driver supports multiple PostgreSQL schemas, with one caveat: for
19 performance reasons, data about the search path, sequence names, and so
20 forth is queried as needed and CACHED for subsequent uses.
21
22 For this reason, once your schema is instantiated, you should not
23 change the PostgreSQL schema search path for that schema's database
24 connection. If you do, Bad Things may happen.
25
26 You should do any necessary manipulation of the search path BEFORE
27 instantiating your schema object, or as part of the on_connect_do
28 option to connect(), for example:
29
30 my $schema = My::Schema->connect
31 ( $dsn,$user,$pass,
32 { on_connect_do =>
33 [ 'SET search_path TO myschema, foo, public' ],
34 },
35 );
36
38 Check the list of additional DBIC resources.
39
41 This module is free software copyright by the DBIx::Class (DBIC)
42 authors. You can redistribute it and/or modify it under the same terms
43 as the DBIx::Class library.
44
45
46
47perl v5.32.0 2020-07-28 DBIx::Class::Storage::DBI::Pg(3)