I am trying to join the results of an elasticsearch filter query.
The history index has two fields - id and result.
I want to create a field in the new index called results that contains both the id and the result e.g results => 1-B, 2-A, 3-C, 4-A.
I have tried both of the following but both only give me an array of nulls. How do you properly reference the fields
elasticsearch {
hosts => ["192.168.1.42"]
index => "history"
query => "id:%{[ID]}"
fields => {
"id.result" => "results"
}
result_size => 1000
}
elasticsearch {
hosts => ["192.168.1.42"]
index => "history"
query => "id:%{[ID]}"
fields => {
"history-%{id}.history-%{result}" => "results"
}
result_size => 1000
}
elasticsearch {
hosts => ["192.168.1.42"]
index => "history"
query => "id:%{[ID]}"
add_field => { "elections" => "%{election_id}.%{voted}" }
result_size => 1000
}