Query Drupal Nodes By Type And Count
Posted:
Friday, September 5th, 2014Last modified:
Sunday, March 29th, 2015Mysql query to show the number of nodes of each type.
select type, count('nid') as count from node group by type;
Example
mysql> select type, count('nid') as count from node group by type; +--------+--------------------------+ | count | type | +--------+--------------------------+ | 61 | article | | 8 | event | | 42 | page | | 1684 | promo | | 224 | recipe | | 716 | video | | 22 | webform | +--------+--------------------------+
Available Wiki Topics
The operator of this site makes no claims, promises, or guarantees of the accuracy, completeness, originality, uniqueness, or even general adequacy of the contents herein and expressly disclaims liability for errors and omissions in the contents of this website.