Hi, I am calling a stored procedure from powerapp and storing the result set in a collection. This works fine so long as data is returned from the stored procedure. However I am having issues when no data is returned.
I trigger the stored procedure using and store the results using
ClearCollect(queryResults,GetSQLData.Run(inpSearch.Text));
Within the flow after executing the stored procedure I check to see if the result set is empty. If it is not empty a response action is triggered to return the data using a schema generated from the the sample returned from the execute stored procedure step. This all works as expected.
If the result set is empty another response is triggered, Ultimately I need to do here is return the blank array of data. I have used the same schema but removed the required fields elements. However when I call this from powerapp using a search that I know will generate no results I get a JSON parse error expected array received object.
Any help appreciated

Report
All responses (
Answers (