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

Can't deploy and therefore can't delete

Hi all,


We have had an apex class in place for some time now that queries a significant number of accounts at one point. 13,000 prospect accounts have been added to our org and as a result we receive a heap size error every time we try to run the code and when deploying due to the test case related to the class. I have deleted the class and the apex page in our sandbox org, but I am wondering how I push these changes over to production using change sets when the apex test fails every time. Any help would be greatly appreciated.




What error message are the tests failing with?


Simply deleting a clss that was being referenced by other classes will cause compilation errors and you then won't be able to deploy.


AS previously stated, it is a heap size error. I know that there are no other pages or classes that with dependencies on this class and I would simply like to know how to push the delete over to production.


I didnt really understood that..................did you really need to delete your class and page from the sandbox??


you could have used a 'limit' in the query and then you might have overwrite in the production.......correct me if I am wrong...