Database API

Adding support for LEFT JOINs and IS NULL conditions to Drupal's EntityFieldQuery has been asked for in d.o. issue queues and discussed over and over again. Although in Drupal 8 EntityFieldQuery has been rewritten, and now supports exists() and notExists() conditions, implementing it in Drupal 7 is still slightly hack-ish. Doing it in dynamic, parametrisable way however seems to be something new entirely.