# Graph to display only last months entries

**URL:** <https://community.glideapps.com/t/graph-to-display-only-last-months-entries/72931>\
**Category:** Ask for Help\
**Created:** [April 29, 2024, 12:32pm UTC](https://community.glideapps.com/t/graph-to-display-only-last-months-entries/72931 "2024-04-29T12:32:13Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![kickso](https://avatars.discourse-cdn.com/v4/letter/k/3bc359/32.png) [@kickso](https://community.glideapps.com/u/kickso)\
**Post date:** [April 29, 2024, 12:32pm UTC](https://community.glideapps.com/t/graph-to-display-only-last-months-entries/72931/1 "2024-04-29T12:32:13Z")

</div>

Hi there, I am trying to display a graph that plots the numerical output from a report of underlying companies (e.g. Monthly headcount).

I want it to only display records submitted in the latest month (I have a date submitted field in Airtable e.g. 04/04/2024) and would only want the records relating to April 2024.

When I plot them on the graph now, it automatically aggregates all months from the Airtable data, whereas I just want the most recent period/30 days without having to hard code the filters each month.

Do you have any suggestions?

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [April 29, 2024, 12:34pm UTC](https://community.glideapps.com/t/graph-to-display-only-last-months-entries/72931/2 "2024-04-29T12:34:50Z")

</div>

In the Glide Data Editor, create a Math column using the formula `Now-30`, where Now is the special “Now” value (current date/time).

That should return a Date that is always 30 days in the past.

Then filter your chart where Submitted On is on or after that date.

---

<div class="post-metadata">

**Author:** ![kickso](https://avatars.discourse-cdn.com/v4/letter/k/3bc359/32.png) [@kickso](https://community.glideapps.com/u/kickso)\
**Post date:** [April 29, 2024, 1:52pm UTC](https://community.glideapps.com/t/graph-to-display-only-last-months-entries/72931/3 "2024-04-29T13:52:38Z")

</div>

you so smart

---

<div class="post-metadata">

**Author:** ![kickso](https://avatars.discourse-cdn.com/v4/letter/k/3bc359/32.png) [@kickso](https://community.glideapps.com/u/kickso)\
**Post date:** [April 29, 2024, 2:32pm UTC](https://community.glideapps.com/t/graph-to-display-only-last-months-entries/72931/4 "2024-04-29T14:32:31Z")

</div>

btw, do you know how I can only show one linked record per company? E.g. the most recent report if multiple filed within the Now-30 period? It’s stacking together headcount and displaying 2x reports of 10 headcount as 20.

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [April 29, 2024, 2:50pm UTC](https://community.glideapps.com/t/graph-to-display-only-last-months-entries/72931/5 "2024-04-29T14:50:45Z")

</div>

Not sure if I fully get it, but if I’m reading correctly then you could probably create a Query column in your Companies table that targets the Submissions table, filter that by Date Submitted and CompanyID, do a rollup through that to get the counts, and then use the Companies table as the source of a chart.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/system/32/53398_2.png) [@system](https://community.glideapps.com/u/system)\
**Post date:** [May 6, 2024, 2:51pm UTC](https://community.glideapps.com/t/graph-to-display-only-last-months-entries/72931/6 "2024-05-06T14:51:34Z")

</div>

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
