You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to store any random arbitrary JSON structure (schema-less) in this field.
I can create this doc and it returns a value of type elasticsearch_dsl.document.InnerDoc.
I am unable to query this.
Assuming the value of extras={'sytem': {'code': 'foo', 'valueType': 'bar'}}
Following dint work:
Earlier I had this field dynamic=True and the following query 1 (above) was working fine. But I had to move it to dynamic=False to support schemaless JSON.
Any help would be appreciated!
The text was updated successfully, but these errors were encountered:
I have an ES index with many fields, one of them is:
I want to store any random arbitrary JSON structure (schema-less) in this field.
I can create this doc and it returns a value of type
elasticsearch_dsl.document.InnerDoc
.I am unable to query this.
Assuming the value of
extras={'sytem': {'code': 'foo', 'valueType': 'bar'}}
Following dint work:
ResourceDocument.search().filter("query_string", query="foo", fields=['extras__system__code']).execute().hits
ResourceDocument.search().query(Q('nested', path='extras', query=Q('exists', field='extras.system.code'))).execute().hits
ResourceDocument.search().query(Q('nested', path='extras', query=Q('exists', field='extras__system__code'))).execute().hits
Earlier I had this field
dynamic=True
and the following query 1 (above) was working fine. But I had to move it to dynamic=False to support schemaless JSON.Any help would be appreciated!
The text was updated successfully, but these errors were encountered: