projects
/
dbsrgits/DBIx-Class-Historic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
add money type support
[dbsrgits/DBIx-Class-Historic.git]
/
lib
/
DBIx
/
Class
/
Storage
/
DBI
/
Sybase
/
NoBindVars.pm
diff --git
a/lib/DBIx/Class/Storage/DBI/Sybase/NoBindVars.pm
b/lib/DBIx/Class/Storage/DBI/Sybase/NoBindVars.pm
index
5053bae
..
0ca20a4
100644
(file)
--- a/
lib/DBIx/Class/Storage/DBI/Sybase/NoBindVars.pm
+++ b/
lib/DBIx/Class/Storage/DBI/Sybase/NoBindVars.pm
@@
-51,6
+51,17
@@
sub should_quote_value {
return $self->next::method(@_);
}
+sub transform_unbound_value {
+ my ($self, $type, $value) = @_;
+
+ if ($type =~ /money/i && defined $value) {
+ $value =~ s/^\$//;
+ $value = '$' . $value;
+ }
+
+ return $value;
+}
+
1;
=head1 NAME