Querying a complex doc in elasticsearch


(Ameni) #1

Hello,
I am new in the world of elasticsearch.

We are dealing in our project with complex docs that we store in our elasticsearch database.

This is a part of our doc:
"AAA": [
{
"SSS": {
"Description": {
"Detail": [
{
"Name": "A9",
"Infos": "...."
},
{
"Name": "A8",
"Infos": "...."
},
{
"Name": "A7",
"Infos": "...."
},
{
"Name": "A6",
"Infos": "...."
},
{
"Name": "A5",
"Infos": "...."
},
{
"Name": "A4",
"Infos": "...."
},
{
"Name": "A3"
"Infos": "...."
},
{
"Name": "A2",
"Infos": "...."
},
{
"Name": "A1",
"Infos": "...."
}
]
}
}
}
]
}

I want a query that return the " Infos" & "Name" fields specific to "Name":"A1" for example.
In other terms I want a query that return this part of the doc:
"AAA": [
{
"SSS": {
"Description": {
"Detail": [
{
"Name": "A1",
"Infos": "...."
}
]
}
}
}
]
I am trying all the day and it didn't work for me.
Can anyone help me.
Thanks in advance.


(system) #2

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.