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
RonakPatel.ceRonakPatel.ce 

Regex too complicated

hi,

 

i import data though csv file but when data is more than 1000 then it gives me Error

 

 

System.LimitException: Regex too complicated

 

Can anybody give me Explanation ?

Best Answer chosen by Admin (Salesforce Developers) 
Navatar_DbSupNavatar_DbSup

Hi,

This message comes due to size of the files.  It looks like Email Services provides an entry point that allows developers to push in data sizes that far exceed the heap limits. The regex seems to be failing because of the heap supporting the regex. The only alternative is to cut the file sizes down or choose another integration approach.

 

For more detail follow the below link:

 

http://boards.developerforce.com/t5/Apex-Code-Development/Regex-too-complicated-error-for-large-volume-of-data-and-a/td-p/178769

 

Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved. 

All Answers

Navatar_DbSupNavatar_DbSup

Hi,

This message comes due to size of the files.  It looks like Email Services provides an entry point that allows developers to push in data sizes that far exceed the heap limits. The regex seems to be failing because of the heap supporting the regex. The only alternative is to cut the file sizes down or choose another integration approach.

 

For more detail follow the below link:

 

http://boards.developerforce.com/t5/Apex-Code-Development/Regex-too-complicated-error-for-large-volume-of-data-and-a/td-p/178769

 

Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved. 

This was selected as the best answer
RonakPatel.ceRonakPatel.ce

Thanks

 

For your Reply

mariagusmariagus

Hi,

 

I had the same issue when I tried to process a CSV file of nearly 4MB. But I couldn't ask customers to send me smaller files, so I had to find another way to do it.

 

Finally I developed a Batch Apex process with a custom Iterator. For futher information: http://developer.financialforce.com/customizations/importing-large-csv-files-via-batch-apex/

 

I hope this helps.

James KentJames Kent

I took the FinancialForce code, which is a really good solution, and gave it a once over.  Apex Row Iteration Class post.