How to get nodes by custom field value using EntityFieldQuery? I am trying many options, e.g:

$entities = $nodeQuery-&gt;entityCondition('entity_type', 'node')
    -&gt;entityCondition('bundle', 'article') 
    -&gt;fieldCondition('field_archived','field_archived_value', '1', '=') 
    -&gt;pager(10)
    -&gt;execute();


field_archived is the machine name of my custom field added to article. field_archived_value is a column inside field_data_field_archived table.

In this case I am getting error:

PDOException: SQLSTATE[42S22]: [Microsoft][SQL Server Native Client 11.0][SQL Server]Invalid column name 'field_archived_field_archived_value


What I am doing wrong here?
The correct code is the following one.

$entities = $nodeQuery-&gt;entityCondition('entity_type', 'node')
  -&gt;entityCondition('bundle', 'article') 
  -&gt;fieldCondition('field_archived','value', '1', '=') 
  -&gt;pager(10)
  -&gt;execute();


Instead of 'field_archived_value' you need to use 'value'.