I am on a custom entity with custom fields and i try to get all empty record on date field :
Field was create with CCK, so the field storage has a table.
$query = \Drupal::entityQuery('test_entity');
$query->condition('field_date',NULL,'=');
$ids=$query->execute();
This doesn't work for date field.
INNER JOIN
on the field data table because you've included it in the conditions, and there's no data, so nothing to compare to null. Hence no results. – Clive♦ Oct 13 '16 at 12:46