Hello
I am new to Elasticsearch and encountered some difficulties with the mapping and transfer of my SQL-data. I hope you can help.
The orginal data has a foreign key that can't be directly used in elasticsearch (AFAIK).
"mappings" : {
"my_type" : {
"properties" : {
"pk" : {"type": "integer" },
"fk" : {"type": "integer" },
"a" : { "type" : "string" },
"b" : { "type" : "string" },
...
}
}
}
For an aggregation, I want to put documents in a bucket (e.g. based on values of "a") and then add all documents whose value for "fk" corresponds to the "pk" of a document already in the bucket.
Denormalization would be problematic since there are many fields.
Nesting is problematic because there might be several layers.