+ Start a Discussion
Pranav MarathePranav Marathe 

Salesforce Page Load Error


We have developed an application using Visualforce pages, components and Apex. The functionality works perfectly fine in Sandbox without any issues, but it fails OCCASIONALLY in Production.
Typically I receive following errors

core.apexpages.exceptions.ApexPagesHandledException: Object type not accessible. Please check permissions and make sure the object is not in development mode: Your query request was running for too long.


Time Limit exceeded...!

As mentioned before, these errors appear on a random basis on the first load. You can say once or twice a day. These errors have never appeared in Sandbox. The query has been restricted to fetch only 2000 records.

There is no error information in debug logs as well.

We have even refreshed the Sandbox (FULL) to find the reason, but it runs perfectly without any issue in Sandbox.

Any direction to solve this problem?

ShashankShashank (Salesforce Developers) 
Can you may be post the query that you are using so that I can have a look?
Surabhi MenonSurabhi Menon
Hi Pranav,

Did you find any solution for this as we are also facing the same issue in production.


Pranav MarathePranav Marathe
We didn't find any solution..
Navneet kNavneet k
If you have full sandbox with exact similar data then you can regenerate in Snadbox also, it seems High volume data issue, you have to normalize your code and query.
Pranav MarathePranav Marathe
It is a Full Sandbox (Read my question again).
Navneet kNavneet k
ok! If you paste your code here would help to resolve issue.
Pranav MarathePranav Marathe
Check this code block public ApexPages.StandardSetController stdController { get { if(stdController == null) { stdController = new ApexPages.StandardSetController(Database.getQueryLocator(strQuery + ' LIMIT 1')); stdController.setFilterId(strListViewOption); Set setResultIds = new Set(); //Page size set to higher value so iteration will be less if(stdController.getResultSize()