This question might be more towards the approach than the technical side. The scenario is the following:
I have to run a scheduler to delete some records. The record size is always going to be less than 10K!
Can I retrieve all the results in a list like:
List <sObject> listsObject = [Select Id from sObject where Test__c = true Limit 9000]; Delete listsObject;
Will this be able to delete all the records in the list?! OR Will this only delete the 200 records? Please let me know.
Also, I know I could follow the batch Apex Approach but I want to know first if this will work, and if this certainly works I dont have to write Batch Apex and then schedule it.