You are here

function _termstatus_count_nullstatus in Taxonomy Term Status 7

Return the number of taxonomy terms which do not have any status record.

1 call to _termstatus_count_nullstatus()
termstatus_settings in ./termstatus.admin.inc
Term status settings form.

File

./termstatus.admin.inc, line 49
Administrative interface for the taxonomy term status module.

Code

function _termstatus_count_nullstatus() {
  $count = db_query('SELECT COUNT(*) FROM {taxonomy_term_data} AS td LEFT JOIN {termstatus} AS ts ON td.tid = ts.tid WHERE ts.status IS NULL')
    ->fetchField();
  return $count;
}