Print this page

Why do I get the QUERY_TIMEOUT error when using the Data Loader to extract just a few records?

Knowledge Article Number 000007178
Description
Why do I get the QUERY_TIMEOUT error when using the Data Loader to extract just a few records?
Resolution
Even though it doesn't return these records back to the Data Loader, SOQL is querying against softdeleted (recycle bin) records by default.
If there are enough soft deleted records in the system, it may cause a timeout.

Resolution

Add the following filter/condition to your export statement:
  •  IsDeleted = FALSE
Example:

Select Id, Name FROM Account where IsDeleted = FALSE




promote demote