reduce RaffleDAO getRaffles and getFilteredDataFromTable complexity