From aa8453058f113ee1f10f4246098b41f5983918c9 Mon Sep 17 00:00:00 2001 From: Unknown Date: Sun, 18 Feb 2024 14:49:54 +0000 Subject: [PATCH] Fix for SQLite date not supported datatype --- lib/logstash/inputs/sqlite.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/logstash/inputs/sqlite.rb b/lib/logstash/inputs/sqlite.rb index ed8badd..2947433 100644 --- a/lib/logstash/inputs/sqlite.rb +++ b/lib/logstash/inputs/sqlite.rb @@ -162,7 +162,11 @@ def run(queue) # store each column as a field in the event. row.each do |column, element| next if column == :id - event.set(column.to_s, element) + if element.instance_of? Date + event.set(column.to_s, element.to_s) + else + event.set(column.to_s, element) + end end queue << event @table_data[k][:place] = row[:id]