Hello

I've discovered the issue with BLOB column handling with
DBIx::Class::Storage::DBI::Oracle::Generic
(the column value doesnt want to go into base)

the key links:

http://search.cpan.org/~pythian/DBD-Oracle-1.21/Oracle.pm#Binding_for_Updates_and_Inserts<http://search.cpan.org/%7Epythian/DBD-Oracle-1.21/Oracle.pm#Binding_for_Updates_and_Inserts>
http://search.cpan.org/~pythian/DBD-Oracle-1.21/Oracle.pm#Placeholder_Binding_Attributes<http://search.cpan.org/%7Epythian/DBD-Oracle-1.21/Oracle.pm#Placeholder_Binding_Attributes>

http://search.cpan.org/~ash/DBIx-Class-0.08010/lib/DBIx/Class/Storage/DBI.pm#bind_attribute_by_data_type<http://search.cpan.org/%7Eash/DBIx-Class-0.08010/lib/DBIx/Class/Storage/DBI.pm#bind_attribute_by_data_type>

And here is a suggesting quick patch, based on info from links:


use DBD::Oracle qw(:ora_types);


sub bind_attribute_by_data_type {
    my ($self,$type) = @_;

    if ($type eq 'BLOB') {
        return { 'ora_type' => SQLT_BIN };
    } elsif ($type eq 'CLOB') {
        return { 'ora_type' => SQLT_CHR };
    } else {
        return;
    }
}

(these values are valid for DBD::Oracle build upon Oracle 10.2 or smth, so
this patch should be a bit complicated).


Hope this will save time for someone.

Regards.
_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive: http://www.grokbase.com/group/[EMAIL PROTECTED]

Reply via email to