Linked Questions

3 votes
2 answers
12k views

Help with :Too many SOQL queries: 101 - How to debug where it's failing [duplicate]

Having a problem with below code reaching too many queries (we have Hubspot and I'm receiving the error on HubSpot_Inc in my tests).I avoided using queries in loops, so looking for suggestions on how ...
ajl7519's user avatar
  • 169
10 votes
2 answers
2k views

Too many SOQL queries

This question has been asked before, but none of the answers on those threads have helped so far. Getting the following error when trying to deploy a test class from the sandbox to production in the ...
Brian's user avatar
  • 566
3 votes
2 answers
2k views

I am getting this error: System.LimitException: Too many SOQL queries: 101 [duplicate]

I am getting this error System.LimitException: Too many SOQL queries: 101 when I run the class bellow. It seems like it is affecting all the triggers linked to NRProducts__c Object(This object has 45,...
Carlos's user avatar
  • 1,881
0 votes
1 answer
4k views

Error: 'System.LimitException: Too many SOQL queries: 101' [duplicate]

I am getting an error: 'System.LimitException: Too many SOQL queries: 101' when I run a testing class for another class similar to this one, which is located in the same Object. I am trying to use ...
Carlos's user avatar
  • 1,881
-1 votes
2 answers
859 views

Too Many SOQL Queries 101 though limit 100 [duplicate]

I am getting this error though limit 100 is provided in SOQL statement.Can someone please suggest a way out here? Apex code: public class Attachments_11{ public List<attachmentCaseWrapper> ...
Testing_SFDC's user avatar
  • 2,950
0 votes
2 answers
756 views

HELP : System.LimitException: Too many SOQL queries: 101 [duplicate]

This is my first trigger, on my custom object Affaire: Trigger MissionrollupAffairesDossier on Affaire__c (after delete, after insert, after update, after undelete) { //Cumul de montants d'affaire ...
Dahan's user avatar
  • 11
0 votes
1 answer
882 views

Failure Message: "System.LimitException: Too many SOQL queries: 101", [duplicate]

I am deploying my code to production and i am getting the below error Failure Message: "System.LimitException: Too many SOQL queries: 101", Failure Stack Trace: My trigger trigger ...
user6833's user avatar
  • 543
0 votes
1 answer
446 views

Apex Error: Too Many SOQL Queries: 101 [duplicate]

I am currently trying to update a set of data, but I am receiving the error "Too Many SOQL Queries: 101". From what I have seen while searching around, this is normally an error that occurs while ...
Katie Swol's user avatar
-1 votes
2 answers
171 views

System.LimitException: Too many SOQL queries 101 [duplicate]

System.LimitException: Too many SOQL queries 101 I am getting this error on below line List <Call_Report_Attendees__c> cra = [Select id, currencyIsoCode,Call_Report__c from ...
Sandeep Dharwar's user avatar
0 votes
0 answers
33 views

Too many soql query in Event relation [duplicate]

List<Event> newEventModuled = new List<Event>(); newEventModuled = [select Ownerid,Subject,what.name,Description__c,ShowAs,Time_Spent_In_minutes__c, ...
Ashutosh Srivastava's user avatar
109 votes
11 answers
42k views

How do I start to debug my own Apex code?

Sometimes questions are posted here that would best be answered by helping the questioner learn how to do their own debugging. (Remember that proverb?) I'd like to have something to link to on this ...
Keith C's user avatar
  • 136k
2 votes
2 answers
28k views

Workarounds to avoid Error: "Too many SOQL queries: 101"

I am hitting salesforce limits in 3 cases: When user is adding a document from a large list of docs which is greater than 100? (Eg error when they are trying to pull a document from their library ...
user2507024's user avatar
1 vote
3 answers
2k views

Error 'System.LimitException: Too many SOQL queries: 101' while deploying code

trigger Order_AIUD on Order (after insert, after update, after delete) {Map<Id, List<Order>> acctIdOpptyListMap = new Map<Id, List<Order>>(); Set<Id> acctIds = new ...
akng105's user avatar
  • 71
1 vote
1 answer
3k views

System.LimitException: Too many SOQL queries: 101

I am getting "System.LimitException: Too many SOQL queries: 101" when I am trying to load 500 opptys through dataloader.I think insert statement in for loop is where it is failing.But it ran ...
sfdc's user avatar
  • 13.7k
3 votes
1 answer
3k views

Too many SOQL queries: 101 in apex class. How to count results?

List<tempcon1> listoftemp; CheckContactController chk = new CheckContactController(); public List<tempcon1> getconValues() { listoftemp = new List<tempcon1>(); for (...
Eagerin Sf's user avatar
  • 1,085

15 30 50 per page