The communication field below is a part of a larger json file. The field i am trying to index is code
"communication": [
{
"language": {
"coding": [
{
"code": "en-US",
"system": "http://hl7.org/fhir/ValueSet/languages",
"display": "English (United States)"
}
]
}
}
]
I have written this Create Index code and its executing well , No errors
create index `patient_communication_language_coding_code` on
neuron(distinct array
(distinct array c.code for c in v.language.coding end)
for v in communication end)
but when I try to query It doesn’t select the Index or Using it …
select * from `neuron` as r use index(patient_communication_language_coding_code)
where any comm in r.communication satisfies
any coding in comm.language.coding satisfies coding.code = 'en-US'
end
end;
The above query is valid. I have previously indexed on array of array in couchbase but this situation is array.object.array.object which is the code
field. There are no syntax error . I am i doing something wrong or it is not possible to index array this deep?