I am trying to create a pie chart in dashboard using arcade.
I am query a layer by a list of values and create some values for the pie.
The basic lines is
var sql = "GlobalID = '" + globalId + "'";
var featureLocation = Filter(fs_location, sql);
where the golbalID change in a loop.
It all works fine when the feature set contain values. The problem is when it return nothing.
I tried "isEmpty(featureLocation)" but it return an error.
I tried some simple loop:
var c = 0
for(var s in featureLocation)
{
c = c + 1
}
it return an error too.
Unlike many of the examples I do not have $feature here.
Any good way to understand nothing is coming back and does not get an error?
Thanks