You are here

function data_taxonomy_data_delete_query_alter in Data 6

Implementation of hook_data_delete_query_alter().

File

data_taxonomy/data_taxonomy.module, line 162
Hooks and API functions for Data Node module.

Code

function data_taxonomy_data_delete_query_alter($query, $table_name) {
  if ($info = data_taxonomy_get_info($table_name)) {
    $table_name = db_escape_table($table_name);
    $query
      ->addSubject('data_taxonomy');
    $query
      ->addJoin('data_taxonomy', "{$table_name}.{$info['id']} = data_taxonomy.id AND data_taxonomy.data_table_name = '{$table_name}'", 'LEFT JOIN');
  }
}