By hekele on
Does anyone has any idea how to create a EntityFieldQuery on nodes without a specific field?
For example: 10 nodes of different content-types, 3 of them with a field called "field_counter", 7 without this field ...
How do I get the 7 nodes without (!) the field "field_counter"?
$query = new EntityFieldQuery();
$query->entityCondition('entity_type', 'node')
->fieldCondition('field_counter', ...);
Comments
You should use the entityCondition('bundle'...
This should return the expected results: