YUKI Hiroshi
null+****@clear*****
Thu Sep 12 18:33:21 JST 2013
YUKI Hiroshi 2013-09-12 18:33:21 +0900 (Thu, 12 Sep 2013) New Revision: c868032f79169be40c459bec90a102cef595e3dd https://github.com/droonga/fluent-plugin-droonga/commit/c868032f79169be40c459bec90a102cef595e3dd Message: GroongaCommandConverter: Split "load" command to multiple "add" commands correctly Modified files: lib/groonga_command_converter.rb Modified: lib/groonga_command_converter.rb (+3 -1) =================================================================== --- lib/groonga_command_converter.rb 2013-09-12 18:33:07 +0900 (0c2fc9c) +++ lib/groonga_command_converter.rb 2013-09-12 18:33:21 +0900 (85a4fe5) @@ -106,14 +106,16 @@ module Droonga :table => @command[:table], } + record_values = {} record.each_with_index do |value, column_index| column = columns[column_index] if column == "_key" body[:key] = value else - body[:values][column.to_sym] = value + record_values[column.to_sym] = value end end + body[:values] = record_values unless record_values.empty? yield create_envelope("add", body) end -------------- next part -------------- HTML����������������������������...Download