Error getting data frame. root object doesn't exist in the response. Root selector:status

Grafana V9.0.2

I have a display panel using the Infinity data source for json. My URL gathers and displays data in the panel just fine so long as there are records to display.

However, if the URL returns an empty array because there are no values to display, the query returns: “error getting data frame. root object doesn’t exist in the response. Root selector:status”

This is because the http response returns an empty array like this:

I am missing a configuration in the Parsing options & Result fields to handle an empty array in the json I get back. But I don’t know what I am missing.

What’s the json response looks like in both the cases ( results and empty state ) ?

Hi yesoreyeram:

case 1 (empty) is a blank array like this:

Case 2: [{“taskID”:“38618”,“dicomDeviceName”:“dcm4chee-arc”,“queue”:“StgCmtSCP”,“type”:“STGCMT_SCP”,“status”:“WARNING”,“createdTime”:“2023-08-30T13:07:00.679+0000”,“updatedTime”:“2023-08-30T13:07:00.754+0000”,“scheduledTime”:“2023-08-30T13:07:00.678+0000”,“processingStartTime”:“2023-08-30T13:07:00.689+0000”,“processingEndTime”:“2023-08-30T13:07:00.754+0000”,“outcomeMessage”:"Return Storage Commitment Result[successful: 0, failed: 1] to AE: AET,"LocalAET:“AET2”,"RemoteAET:"AET}]

Thanks for the reply.

In case 2, i can’t see status as root object. Am I missing something in the json. Try removing the status from the root selector. ( In most cases, root selector should return an array of objects)