Created
April 22, 2012 12:39
-
-
Save 1stevengrant/2463968 to your computer and use it in GitHub Desktop.
count entries with given status/channel in expressionengine
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{exp:query sql=" | |
SELECT | |
COUNT(entry_id) AS total_entry_count | |
FROM | |
exp_channel_titles | |
WHERE | |
channel_id = 1 AND status = 'open' | |
"} | |
{total_entry_count} | |
{/exp:query} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment