You need to sign in to do that
Don't have an account?

Multiple SOQL query's reach limit
I understand that im running to many querys. Whats the proper way to run querys and not reach the limit? Basically im running 24 querys per user, im doing reports on user data and updateing a object with the calculations. Is there some kind of batch i can send and have it give it back to me. Or do i have to export the results into mysql and run my calcs then send it back? Whats a good way to do something like this with so many querys? Thanks in advance.
If I got it right, you're doing an iteration on a collection of users, and in that iteration you do soql queries ?
The best practise is to get a list of all user Id's, and then make a single query per object you want to collect and do:
Subsequently you can process the result and map it to for instance map<id, list<object>> and perform your logic with this.
.