question

MandeepChauhan-6761 avatar image
0 Votes"
MandeepChauhan-6761 asked ryanchill answered

Cognitive search index on all subfields of a Edm.ComplexType

As part of Azure Cognitive Search, I am trying to create an index on CosmosDB container where my documents are in following format.

 {
     "id": "123456789",
     "layerid": 39,
     "searchable": {
         "Asset_Id": "P0004",
         "SAP_Id": "A001-BCD"
     }
 }

I am able to create a simple index by specifying a particular field e.g. make "layerid" searchable, retrievable etc.
What I need is to index all subfields of the field "searchable" without specifying the name of the subfield itself.
In the scenario that I am working on, the subfields of "searchable" field is not fixed however the structure is fixed.
Is there a way in Cognitive search to cater this scenario?



azure-cognitive-servicesazure-cognitive-search
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

ryanchill avatar image
0 Votes"
ryanchill answered

Hi @MandeepChauhan-6761,

Unfortunately, no. Dynamic schemas being loaded on the fly aren't supported. If the fields under "searchable" changes, you'll will need to update the index with the new fields as instructed in Creating complex fields.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.