I don't write code, so bear with me.
I have a portion of an Apex Class that pulls a list of record types for Cases. However, I need to add a criteria here that then looks at the received records and only includes the records where a certain field is filled in.
List<RecordType> residentialRecordTypes = [SELECT Id FROM RecordType WHERE (DeveloperName = 'Residential' OR DeveloperName = 'Carpet' OR DeveloperName = 'Manufacturing_Distribution' OR DeveloperName = 'Residential_Service_Claims' OR DeveloperName = 'Mannington_Rubber') AND SobjectType = 'Case' AND Id in: casesByRecordTypeId.keySet() LIMIT 1];
So I essentially need to add something like:
AND Case.Division__c LIKE 'Residential'
Any idea how I would do this?