function sitealias_get_databases_from_record

8.0.x sitealias.inc sitealias_get_databases_from_record(&$alias_record)
6.x sitealias.inc sitealias_get_databases_from_record(&$alias_record)
7.x sitealias.inc sitealias_get_databases_from_record(&$alias_record)
3.x sitealias.inc sitealias_get_databases_from_record(&$alias_record)
4.x sitealias.inc sitealias_get_databases_from_record(&$alias_record)
5.x sitealias.inc sitealias_get_databases_from_record(&$alias_record)
master sitealias.inc sitealias_get_databases_from_record(&$alias_record)

Return the databases record from the alias record

@returns A databases record (always in D7 format) or NULL if the databases record could not be found.

Parameters

$alias_record: A record returned from drush_sitealias_get_record

4 calls to sitealias_get_databases_from_record()
drush_archive_dump in commands/core/archive.drush.inc
Command callback. Generate site archive file.
drush_sql_sync_init in commands/sql/sync.sql.inc
Sql sync init function. Bootstrap either the source or the destination site. At least one of the sites must be local for this to work; if both sites are remote, then it clearly will not be possible to bootstrap to either of them. If both are local,…
drush_upgrade_fix_db_url in commands/core/upgrade.drush.inc
Replace db_url with DB name from target. updatedb will later append a DBTNG compatible version.
drush_upgrade_site_upgrade in commands/core/upgrade.drush.inc
Main command hook for site-upgrade.

File

includes/sitealias.inc, line 621
The site alias API.

Code

function sitealias_get_databases_from_record(&$alias_record) {
  $altered_record = drush_sitealias_add_db_settings($alias_record);

  return array_key_exists('databases', $alias_record) ? $alias_record['databases'] : NULL;
}