You are here

function Sql::get_join_data in Views (for Drupal 7) 8.3

Retrieve join data from the larger join data cache.

Parameters

$table: The table to get the join information for.

$base_table: The path we're following to get this join.

Return value

Drupal\views\Plugin\views\join\JoinPluginBase A Join object or child object, if one exists.

3 calls to Sql::get_join_data()
Sql::ensure_path in lib/Drupal/views/Plugin/views/query/Sql.php
Make sure that the specified table can be properly linked to the primary table in the JOINs. This function uses recursion. If the tables needed to complete the path back to the primary table are not in the query they will be added, but additional…
Sql::ensure_table in lib/Drupal/views/Plugin/views/query/Sql.php
Ensure a table exists in the queue; if it already exists it won't do anything, but if it doesn't it will add the table queue. It will ensure a path leads back to the relationship table.
Sql::queue_table in lib/Drupal/views/Plugin/views/query/Sql.php
Add a table to the query without ensuring the path.

File

lib/Drupal/views/Plugin/views/query/Sql.php, line 692
Definition of Drupal\views\Plugin\views\query\Sql.

Class

Sql
@todo.

Namespace

Drupal\views\Plugin\views\query

Code

function get_join_data($table, $base_table) {

  // Check to see if we're linking to a known alias. If so, get the real
  // table's data instead.
  if (!empty($this->table_queue[$table])) {
    $table = $this->table_queue[$table]['table'];
  }
  return HandlerBase::getTableJoin($table, $base_table);
}