Il seguente errore compare quando si supera il limite del governor di esecuzione (è possibile eseguire fino a un massimo di 100 query SOQL in totale in un'unica chiamata o contesto).
Errore System.LimitException: Too many SOQL queries: (Troppe query SOQL:) 101
Note:
Per correggere il problema, modificare il codice in modo che il numero di query SOQL attivate sia minore di 100.
Se è necessario modificare il contesto, è possibile utilizzare l'annotazione @future, che esegue il codice in modo asincrono.
Dato che Apex viene eseguito su una piattaforma multi-tenant, il motore runtime Apex impone limiti rigidi per garantire che il codice non monopolizzi le risorse condivise.
000386220

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.