Comment to 'How to find accounts without profiles?'
  • You can use the following query to get all emails which don't have any person or org profile associated with it:

    SELECT `email`
    FROM `sys_accounts` AS `a`
    LEFT JOIN `sys_profiles` AS `p` ON ( `p`.`account_id` = `a`.`id`
    AND `p`.`type` != 'system' )
    WHERE `p`.`id` IS NULL