EntityQuery with joins I am trying to get user data by UUID in my custom module and I don't know how to join on users_field_data table to get user fields (email, username, etc.).

My request for the users table works but I don't know how to join.

$query = \Drupal::entityQuery('user')
          -&gt;condition('uuid', $uuid)
          -&gt;execute();
$result = User::loadMultiple($query);
dpm($result);


How can I execute a join with the users table?
The easiest way to load a field from any entity when querying is to use the entityTypeManager:

$users = \Drupal::entityTypeManager()-&gt;getStorage("user")
        -&gt;loadByProperties(['uuid' =&gt; $uuid]); // or any other properties.

foreach ($users as $user) {
    var_dump($user-&gt;field_customfield-&gt;getValue());
}


see:  working-with-the-entity-api

Be careful to not use \Drupal::entityManager, since it is deprecated.