start of backcompat tests
[dbsrgits/DBIx-Class-Schema-Loader.git] / lib / DBIx / Class / Schema / Loader / Manual / UpgradingFromV4.pod
CommitLineData
9cc8e7e1 1=pod
2
3=head1 NAME
4
5DBIx::Class::Schema::Loader::Manual::UpgradingFromV4 - Important Information
6Related to Upgrading from Version 0.04006
7
8=head1 What Changed
9
10=over 4
11
12=item *
13
14add_column
15
16The new Loader detects much more information about columns and sets flags like
17C<is_auto_increment> that it didn't set before.
18
19=item *
20
21RelBuilder
22
23The new RelBuilder will give you much nicer accessor names for relationships,
24so you will no longer have conflicts between a foreign key column and the
25relationship accessor itself.
26
27It will also more correctly infer the relationship type, e.g. some relationships
28that were previously detected as a C<has_many> will now be a C<might_have>
61b33506 29(when it detects a unique constraint on the foreign key column.)
9cc8e7e1 30
31=item *
32
33moniker_map
34
35Table names are now singularized when determining the C<Result> class names. So
36the table C<user_roles> would have become C<UserRoles> in C<0.04006> but now
37becomes C<UserRole> instead.
38
39=item *
40
41Support for more databases
42
43We now support Microsoft SQL Server and Sybase, and there are also improvements
44to the other backends.
45
46=back
47
48=head1 Backward Compatibility
49
50In backward compatibility mode, the Loader will use the old relationship names
51and types, and will not singularize monikers for tables.
52
53To control this behavior see L<DBIx::Class::Schema::Loader::Base/naming>.
54
55=head2 Static Schemas
56
57When reading a C<Schema.pm> from a static schema generated with an C<0.04>
61b33506 58version of Loader, backward compatibility mode will default to on, unless
59overridden with the C<naming> attribute.
9cc8e7e1 60
61=head2 Dynamic Schemas
62
63Dynamic schemas will always by default use C<0.04006> mode.
64
61b33506 65To upgrade a dynamic schema, set the naming attribute (which is proxied to the
9cc8e7e1 66loader) in your C<Schema.pm>:
67
68 __PACKAGE__->naming('current');
69
70=head1 AUTHOR
71
72See L<DBIx::Class::Schema::Loader/AUTHOR> and L<DBIx::Class::Schema::Loader/CONTRIBUTORS>.
73
74=head1 LICENSE
75
76This library is free software; you can redistribute it and/or modify it under
77the same terms as Perl itself.
78
79=cut