Optimize query requests