From db514c4acede6fb83a28ed59e560b074c44d74b9 Mon Sep 17 00:00:00 2001 From: Amir Tuval Date: Fri, 2 Sep 2016 00:37:04 +0300 Subject: [PATCH] mend --- lib/vertica/protocol/frontend/bind.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/vertica/protocol/frontend/bind.rb b/lib/vertica/protocol/frontend/bind.rb index 60d6a33..96fe48b 100644 --- a/lib/vertica/protocol/frontend/bind.rb +++ b/lib/vertica/protocol/frontend/bind.rb @@ -24,6 +24,8 @@ def convert_to_string(val, parameter_type) return '1' if parameter_type.name == 'bool' and TrueClass === val return '0' if parameter_type.name == 'bool' and FalseClass === val + return val.strftime('%Y-%m-%d %H:%M:%S.%6N %z') if Time === val + val.to_s end end