ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Total Weblog Entries on CP Home Incorrect?

April 06, 2012 12:14pm

Subscribe [3]
  • #1 / Apr 06, 2012 12:14pm

    wiley

    37 posts

    Does anyone know how the “Total Weblog Entries” on CP Home is counted?  Mine currently reads 517, but when I execute the following query, I get a total_results count of 958.

    {exp:weblog:entries weblog="weblog1|weblog2|etc.etc." disable="category_fields|categories|member_data|trackbacks" limit="1000" show_expired="yes" dynamic="off" show_future_entries="yes"}
      {if count==1}{total_results}{/if}
    {/exp:weblog:entries}
  • #2 / Apr 09, 2012 12:01pm

    Kyle Cotter

    730 posts

    Hey wiley,

    Can you let me know what version of ExpressionEngine you are using?

    Also, can you run this code in the Database Query Form? (Utilities ›  SQL Manager ›  Database Query Form)

    SELECT COUNT(*) FROM exp_weblog_data;

    Let me know how many results it returns. And compare that number to that of the CP home page, and the query you are using.

    Keep me posted.

    Thanks.

  • #3 / Apr 09, 2012 1:06pm

    wiley

    37 posts

    Thanks for your help, Kyle.  Doing that reminded me I had a stray weblog with a couple old entries in it.  I’ve deleted those.

    Now, the SQL query returns 964.
    My weblog entries query returns 964.

    However, the CP Home page reads 504.

    I’m using version 1.6.7.

    I can upgrade (been meaning to anyway) to see if that fixes the problem.  I can’t do that immediately, but in the next week or so.  I can report back after that.

    Thanks for your help.  If anything comes to mind, let me know.  Otherwise I’ll post again after my upgrade.

  • #4 / Apr 10, 2012 12:05pm

    Shane Eckert

    7174 posts

    Hey wiley,

    I am glad to see that Kyle was able to help you out here.

    Let us know how the upgrade goes and if you run into any snags with the update.

    Cheers,

  • #5 / Jun 19, 2012 5:18pm

    wiley

    37 posts

    Kyle or Shane,

    I figured it out! The discrepancy wasn’t related to the version, but rather to future/expired entries.

    When I use the exp:stats tags, my stats reflect exactly what the CP Home page shows (a lower number than the actual number of entries in my site).  In order to get an accurate count, I seem to need to use a exp:weblog tag and specific “yes” to show expired and future entries.  For example, my site lists bands’ performances…which are almost always either in the future or expired.  For the performances, the exp:stats tag shows zero entries.

    It doesn’t appear that exp:stats can find future or expired entries.  Is that correct?  If so, I’ll need to run weblog tag queries (which is what I’d been doing).  Unfortunately, this is VERY expensive database-wise & PHP-cycle-wise, and the page dies before loading a table of all my weblogs and their accurate counts.

    Anyhow, thought I’d let you know what I’d found.

  • #6 / Jun 20, 2012 12:58pm

    Shane Eckert

    7174 posts

    Hey wiley,

    Thank you for the follow up, it’s much appreciated. You are right about future entries.

    If you need anything else, please just let me know by opening a new thread.

    Cheers,

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases