我想使用我的日志文件以弹性方式将动态值传递给document_id。 示例 - (xx.log文件)
{"level":"info","item_id":"123","message":"Hii","timestamp":"2017-02-02T08:32:09.535Z"}
我想传递我的日志文件字段值" item_id"在我的弹性" document_id" value和我的logstash.conf输出节文件 -
output {
stdout { codec => rubydebug }
elasticsearch {
host => "localhost"
document_id => "%{item_id}"
}
}
答案 0 :(得分:0)
下面是应该正常工作的代码:-
select count(AccountNumber)
from table where (EffectiveDate > '20150101' and LastChangedDate is NULL) or LastChangedDate is NOT NULL
group by AccountNumber
having AccountNumber > 1