1 package DBIx::Class::Storage::DBI::ADO::Microsoft_SQL_Server;
7 DBIx::Class::Storage::DBI::ADO
8 DBIx::Class::Storage::DBI::MSSQL
14 $self->_identity_method('@@identity');
17 sub source_bind_attributes {
21 my $bind_attributes = $self->next::method(@_);
23 foreach my $column ($source->columns) {
24 $bind_attributes->{$column}{ado_size} ||= 8000; # max VARCHAR
27 return $bind_attributes;
30 sub bind_attribute_by_data_type {
31 my ($self, $data_type) = @_;
34 $self->_mssql_max_data_type_representation_size_in_bytes->{$data_type};
37 $res->{ado_size} = $max_size if $max_size;
43 # XXX needs to support varchar(max) and varbinary(max)
44 sub _mssql_max_data_type_representation_size_in_bytes {
47 my $blob_max = $self->_get_dbh->{LongReadLen} || 32768;
67 uniqueidentifier => 100,
74 datetimeoffset => 100,
85 DBIx::Class::Storage::DBI::ADO::Microsoft_SQL_Server - Support for Microsoft
86 SQL Server via DBD::ADO
90 This subclass supports MSSQL server connections via L<DBD::ADO>.
94 The MSSQL specific functionality is provided by
95 L<DBIx::Class::Storage::DBI::MSSQL>.
97 C<_identity_method> is set to C<@@identity>, as C<SCOPE_IDENTITY()> doesn't work
98 with L<DBD::ADO>. See L<DBIx::Class::Storage::DBI::MSSQL/IMPLEMENTATION NOTES>
99 for caveats regarding this.
103 See L<DBIx::Class/CONTRIBUTORS>.
107 You may distribute this code under the same terms as Perl itself.