function schema_invoke in Schema 6
Same name and namespace in other branches
- 5 schema.module \schema_invoke()
5 calls to schema_invoke()
- drush_schema_inspect in ./
schema.drush.inc - A drush command callback.
- SchemaRegressionTest::testInspectionConflict518210 in tests/
schema_regression.test - Test API for adding tables
- schema_compare_schemas in ./
schema.module - Compares two complete schemas.
- schema_compare_table in ./
schema.module - Compares a reference specification (such as one returned by a module's hook_schema) to an inspected specification from the database.
- schema_inspect in ./
schema.module - "Inspect" menu callback.
File
- ./
schema.module, line 162 - The Schema module provides functionality built on the Schema API.
Code
function schema_invoke($op) {
$db_name = variable_get('schema_database_connection', 'default');
if ($db_name !== 'default') {
db_set_active($db_name);
}
// We could be called by other modules (notably Table Wizard or Migrate) in an update
// function, which does not call hook_init(). So, make sure we get our include files included...
schema_require();
global $db_type;
$function = 'schema_' . $db_type . '_' . $op;
$args = func_get_args();
array_shift($args);
$return = call_user_func_array($function, $args);
if ($db_name !== 'default') {
db_set_active('default');
}
return $return;
}