If I have a known set of users eg. by UID $users = {123, 435, 5463, 5678}. And I want to read the value stored in one custom field e.g. field_current_status that has been added to their user object is there any way to read this 1 value for each of them without loading their user objects.
I don't want to load up a lot of data for a lot of users just to get 1 value from each user.
I have looked at many functions including these below;
- field_get_items($entity_type, $entity, $field_name, $langcode = NULL)
- field_view_field($entity_type, $entity, $field_name, $display = array(), $langcode = NULL)
- field_view_value($entity_type, $entity, $field_name, $item, $display = array(), $langcode = NULL)
- user_load_multiple($uids = array(), $conditions = array(), $reset = FALSE)
These all require the the user object to be loaded e.g. with user_load($uid) or in effect do the same.
Is there any Drupal way to do this or must I write a custom DB query?