How to get a second join into hook_views_data? I am trying to make the value of a string (name) found in mymodule_names.name available to Views by means of hook_views_data().  

To get the name, I need to first look up the nid of the node I want to view in a table named mymodule.  This tells me the email-address of user who authored the node.  Then I need to look up the email address in the table mymodule_names, by finding the row where the same email address is in the column mymodule_names.email. What I want returned is the user name attached to that email-address, which  the value of mymodule_names.name in the same row.

The code below is how far I have been able to get. This makes the value of mymodule_names.email available - but getting that is just an intermediary step.  I think I need a second join to get the user name. I am unable to figure out how to do do that.  How should I modify this code to get the data from the second table?

/**
 * Implements hook_views_data().
 */
function mymodule_views_data() {
  $data = array();
  $data['mymodule']['table']['group'] = t('MyModule');
  $data['mymodule']['table']['base'] = array(
    // This is the identifier field for the view.
    'field' =&gt; 'nid',
    'title' =&gt; t('MyModule'),
    'help' =&gt; t('Table contains ...'),
    'weight' =&gt; -10,
  );

  // This table references the {node} table. The declaration below creates an
  // 'implicit' relationship to the node table, so that when 'node' is the base
  // table, the fields are automatically available.
  $data['mymodule']['table']['join'] = array(
    'node' =&gt; array(
      // Primary key
      'left_field' =&gt; 'nid',
      // Foreign key
      'field' =&gt; 'nid',
    ),
  );
  $data['mymodule']['nid'] = array(
  'title' =&gt; t('Title'),
    'help' =&gt; t('Help.'),
  );
  // Join with the email field.
  $data['mymodule']['email'] = array(
    'title' =&gt; t('Email'),
    'help' =&gt; t('Author email.'),
    'field' =&gt; array(
      'handler' =&gt; 'views_handler_field',
      // This is used by the table display plugin.
      'click sortable' =&gt; TRUE,
    ),
    'sort' =&gt; array(
      'handler' =&gt; 'views_handler_sort',
    ),
    'filter' =&gt; array(
      'handler' =&gt; 'views_handler_filter_string',
    ),
    'argument' =&gt; array(
      'handler' =&gt; 'views_handler_argument_string',
    ),
  );
  return $data;
}


(This is a non-standard setup where node.uid cannot be used to get the node author UID.)

I know how to get the name by inserting a subquery with hook_views_query_alter() (see: this answer). The question is about doing without using subquery.
$data['mymodule']['table']['join']['node'] = [

  //Second table for Join

  'left_table' =&gt; 'foo',
  'left_field' =&gt; 'nid',
  'field' =&gt; 'nid',
]


more info: https://api.drupal.org/api/drupal/core%21modules%21views%21views.api.php/function/hook_views_data/8.6.x