After some searching the closest code snippet I've found is:
->fieldCondition('field_name_ref', 'nid', 'NULL', '!=');
This will find everything where the node reference is not null. But if I change the !=
to =
it returns nothing. I've tried all the combinations of values I can think of:
- Passing in
NULL
instead of'NULL'
. - Passing in
array()
- Trying
1, "<"
"", "CONTAINS"
"", "="
0, "="
Plus a few more, just trying all the combinations I can think of.
How can I pull this off?