I am trying to return a list of Accounts
WHERE
(
All Assets on the Account have Asset.Support_Status__c = 'Canceled'
-OR-
There are NO assets on the Account at all
)
AND
The Account has a contact with Contact.Support_User__c <> Null
Both Contact and Asset have a lookup relationship to Account.
Asset.Support_Status__c is a picklist and one of the values is 'Canceled'
All of the queries I have created either do not return the list of accounts I am looking for or error out.
Is this Query possible and can you provide any tips or suggestions on how I can create it or should I use Apex for this?