No data found exception

0 votes
Hi, If there is not any record in the queried game collections then api returns an exception rather than an empty resultset. Is it possible to get an empty resultset? Because some queries might need to check if there is a record already or not. Thanks
asked Feb 7, 2016 in Android by ashemez (10 points)

1 Answer

0 votes

Hi Ashemez,

App42 API by default designed in the way that if there is no data find in the requested query, then prompt an error message. But if you want to configure an empty set, then there are two ways to configure the response as empty set:

  • Manage locally on the client side: You can create one common function which handles all the exception cases and returns your desired response 
  • Using custom code: In Custom code, you can call the same function and return your designed response to the client. Please have a look at this link which will help you write server-side custom code/cloud code and let me know if you need any help from my side. 

Regards,

Himanshu Sharma

answered Feb 8, 2016 by hs00105 (2,005 points)
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on support@shephertz.com
...