Merge 'trunk' into 'storage-interbase'
[dbsrgits/DBIx-Class.git] / lib / DBIx / Class / Storage / DBI / ODBC / Firebird.pm
CommitLineData
dff4c3a3 1package DBIx::Class::Storage::DBI::ODBC::Firebird;
2
3use strict;
4use warnings;
5use base qw/DBIx::Class::Storage::DBI::InterBase/;
6use mro 'c3';
7
dff4c3a3 8=head1 NAME
9
10DBIx::Class::Storage::DBI::ODBC::Firebird - Driver for using the Firebird RDBMS
11through ODBC
12
13=head1 SYNOPSIS
14
32323fc2 15Most functionality is provided by L<DBIx::Class::Storage::DBI::Interbase>, see
dff4c3a3 16that module for details.
17
90489c23 18To build the ODBC driver for Firebird on Linux for unixODBC, see:
19
20L<http://www.firebirdnews.org/?p=1324>
21
1ae0a36c 22=cut
23
32323fc2 24# XXX seemingly no equivalent to ib_time_all in DBD::InterBase via ODBC
25sub connect_call_datetime_setup { 1 }
1ae0a36c 26
32323fc2 27# from MSSQL
9cd0b325 28
32323fc2 29sub build_datetime_parser {
30 my $self = shift;
31 my $type = "DateTime::Format::Strptime";
32 eval "use ${type}";
33 $self->throw_exception("Couldn't load ${type}: $@") if $@;
34 return $type->new(
35 pattern => '%Y-%m-%d %H:%M:%S', # %F %T
36 on_error => 'croak',
37 );
9cd0b325 38}
39
9633951d 40# we don't need DBD::InterBase-specific initialization
41sub _init { 1 }
42
43# ODBC uses dialect 3 by default, good
44sub _set_sql_dialect { 1 }
45
1ae0a36c 461;
47
32323fc2 48=head1 CAVEATS
49
a499b173 50=over 4
51
52=item *
53
32323fc2 54This driver (unlike L<DBD::InterBase>) does not currently support reading or
55writing C<TIMESTAMP> values with sub-second precision.
56
a499b173 57=back
58
dff4c3a3 59=head1 AUTHOR
60
61See L<DBIx::Class/AUTHOR> and L<DBIx::Class/CONTRIBUTORS>.
62
63=head1 LICENSE
64
65You may distribute this code under the same terms as Perl itself.
66
67=cut