From e79575e247386092c234a8add08ebfcd072f12f5 Mon Sep 17 00:00:00 2001 From: ivan Date: Thu, 29 Sep 2011 05:53:56 +0000 Subject: [PATCH] fix DBI binding for negative integers, shoudl fix CCH update, RT#14243 --- FS/FS/Record.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FS/FS/Record.pm b/FS/FS/Record.pm index 5d3d86a7c..bccc8e6d4 100644 --- a/FS/FS/Record.pm +++ b/FS/FS/Record.pm @@ -273,7 +273,7 @@ sub _bind_type { my $bind_type = { TYPE => SQL_VARCHAR }; - if ( $type =~ /(big)?(int|serial)/i && $value =~ /^\d+(\.\d+)?$/ ) { + if ( $type =~ /(big)?(int|serial)/i && $value =~ /^-?\d+(\.\d+)?$/ ) { $bind_type = { TYPE => SQL_INTEGER }; -- 2.11.0