I am creating a node programatically and one of the fields in the node is an entity reference field referencing a user.
I am using the guide from https://www.drupal.org/node/1388922 and the general consensus i gather is that I need to do something like;
$node->field_customer_nid[$node->language] = array( 'target_id' => $form_state['values']['entity id'], 'target_type' => 'node',
My question is where do i pass the values for the target entity(basically the uid)in that array. Is it the target_id or the entity_id because my attempts with either of those is not working.