I am working on a report section where user can access their set of data by year and dates
so there will be more then 5 to 6 queries in the api to retrieve the analytical data from the database. but the issue i am facing is it is getting timeout and returning a Error page of timeout in response instead i want to show custom error message to reduce the time interval of the dates Like "Please reduce the interval between dates to retrieve the data"
So how i can achieve this.Try catch i have used but didnt worked for me
try
{
$data1 =Database->Query1();
$data2 =Database->Query2();
$data3 =Database->Query3();
$data4 =Database->Query4();
$data5 =Database->Query5();
}catch(/Exception $exception){
#Show_custom_error
}
is there any other way by i can achieve this ?