function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ArunaAruna 

Need suggestion and improvement on soql (apex class calls more then 60 soql per transaction )

I need to generate a big report with all the different scenarios and calculations.
you might suggest why don't you use salesforce reporting or other reporting tool :)
But my users wants report in particular formats and different display with colors style etc. So I decided to by using EXCEL functionality which we can do by using API.
I don't have any issue in generating excel but I counted my SOQL  , they are already reached to 63.
my question is will it be any problem if only one apex class will execute 63 soqls in one transaction ?

According governer limits  we can use 100 soql for Synchronous Limit 100 and Asynchronous Limit 200.

can anyone please suggestion is that ok if only one apex class will execute 63
soqls in one transaction

 


 
Prem Anandh 1Prem Anandh 1
We should think for long term process. It may cause issue in future. So we should optimize the code. 

Can you please pass your code? 
ArunaAruna
I cannot send my code its too big.
 
Prem Anandh 1Prem Anandh 1
Okay. Please try to avoid the query to write inside for loop.