Feed json array to Cognitive Search

Thomas 21 Reputation points
2021-03-09T16:25:18.063+00:00

Hi all,

I do have a very simple json file which I have stored in a blob storage account.
My goal is to index it and eventually search through it.

I think I am missing some basic things here but I just cant figure it out ;)

Here's the json:

{
    "pages": [
        {
            "id": 1,
            "title": "Home",
            "url": "125715.htm",
            "text": "bla bla bla bla"
        },
        {
            "id": 2,
            "title": "Legal Notice",
            "url": "33205.htm",
            "text": "yada yada yada"
        }
    ]
}

The data source is set up and I can see the file.
An indexer is set up and I have changed the key to "id" instead of "metadata_storage_path" as the file is always the same (and therefore not unique) but I am trying to get each json array...

However, when saving, it sits at "validating..." forever. When I just save it with "metadata_storage_path" as key, the indexer is created instantaneously.

Any idea how I can achieve this?

Thanks!

Azure AI Search
Azure AI Search
An Azure search service with built-in artificial intelligence capabilities that enrich information to help identify and explore relevant content at scale.
1,062 questions
{count} votes

1 answer

Sort by: Most helpful
  1. ajkuma 26,636 Reputation points Microsoft Employee
    2021-03-18T18:49:09.23+00:00

    To benefit the community/summarizing the comment discussion.

    Thomas-4898 was able to resolve this issue by creating index, indexer and data source manually (but, not with the Import Data wizard).

    Detailed steps below:

    1.Indexing mode JSON Array
    2.documentRoot: /pages

    We currently do not have the option to set the document root in the portal. I have shared this feedback with our product team and is being looked into. However, there is no ETA to share at this time.

    Check out the Parsing nested JSON Arrays section here.

    @Thomas , thanks for the update and your patience!

    -----------------------------------------------------------------------------------------------------------

    To benefit the community find the right answers, please do mark the post which was helpful by clicking on ‘Accept Answer’ & ‘Up-Vote’.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.