# Email stats not showing correct "all time" figures

**URL:** https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053
**Category:** Feature
**Created:** [August 31, 2018, 1:09am UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053 "2018-08-31T01:09:58Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![AstonJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/astonj/32/215041_2.png) [@AstonJ](https://meta.discourse.org/u/AstonJ)
#### Post date: [August 31, 2018, 1:09am UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053/1 "2018-08-31T01:09:58Z")

</div>

In the old stats/dashboard, when looking at emails sent the `All` column is incorrect (on mine, last 30 days is 105k which sounds about right, but all time is showing as 257k - which I know is incorrect as previously it was over 1M).

---

<div class="post-metadata">

### Author: ![mpalmer](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mpalmer/32/45740_2.png) [@mpalmer](https://meta.discourse.org/u/mpalmer)
#### Post date: [August 31, 2018, 1:26am UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053/2 "2018-08-31T01:26:44Z")

</div>

I believe there was recently some work done to remove ancient records in the `email_logs` table, because it was growing without bound and eventually laying waste to entire regions of disk space. Less records in the database could definitely lead to a lower count, if the stats are generated as a simple `COUNT(*) ON email_logs`.

---

<div class="post-metadata">

### Author: ![AstonJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/astonj/32/215041_2.png) [@AstonJ](https://meta.discourse.org/u/AstonJ)
#### Post date: [August 31, 2018, 5:12pm UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053/3 "2018-08-31T17:12:46Z")

</div>

That’s unfortunate - we’ve been using email stats to track progress of the forum 😢

Could there have been a way to get the total and then add it as a single entry so that the stats did not ‘break’ while at the same time taking up next to no space? Anyway to get that now?

---

<div class="post-metadata">

### Author: ![Mittineague](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mittineague/32/114259_2.png) [@Mittineague](https://meta.discourse.org/u/Mittineague)
#### Post date: [August 31, 2018, 8:16pm UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053/4 "2018-08-31T20:16:23Z")

</div>

Some kind of “max id minus count” might give at least an approximation of how many rows were deleted, no?

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [August 31, 2018, 9:30pm UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053/5 "2018-08-31T21:30:23Z")

</div>

> [@AstonJ](#):
>
> we’ve been using email stats to track progress of the forum

I suggest picking a better stat.

---

<div class="post-metadata">

### Author: ![AstonJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/astonj/32/215041_2.png) [@AstonJ](https://meta.discourse.org/u/AstonJ)
#### Post date: [August 31, 2018, 9:49pm UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053/6 "2018-08-31T21:49:13Z")

</div>

> [@Mittineague](#):
>
> Some kind of “max id minus count” might give at least an approximation of how many rows were deleted, no?

Perhaps `All` could just show the most recent row ID? Guess that would be accurate enough?

> [@codinghorror](#):
>
> I suggest picking a better stat.

Thanks for the suggestion but I quite like the email stats - it helps paint a picture of how active the forum is and how interested people are in the content (enough to have email notifications switched on). It was refreshing to see Discourse had this after coming over from other forum platforms.

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [August 31, 2018, 9:53pm UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053/7 "2018-08-31T21:53:05Z")

</div>

Nobody I know looks at email stats for any kind of community health metric other than server load and per-email costs. In fact, this is the first I’ve ever heard of it in five years.

---

<div class="post-metadata">

### Author: ![AstonJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/astonj/32/215041_2.png) [@AstonJ](https://meta.discourse.org/u/AstonJ)
#### Post date: [August 31, 2018, 10:18pm UTC](https://meta.discourse.org/t/email-stats-not-showing-correct-all-time-figures/96053/8 "2018-08-31T22:18:43Z")

</div>

It’s a metric we use to provide some kind of insight about the forum - we use it on our sponsor info page for example.

With regards to tangible use, you already mentioned two. Other than that it’s interesting to weigh up number of emails sent against other stats - such as number of members and posts made. Low number of emails sent could indicate people aren’t interested enough to subscribe to email notifications.
