2 Replies Latest reply on Feb 13, 2019 10:33 AM by Marco Peters

# Selecting Pageviews for a specific article/month

I have tried to wrap my head around this for hours but need your help now.

Scenario:

• We have a website with news articles.
• These news articles have always a unique publishing date, e.g. January 2019
• Since these articles stay on the website for a longer time, Pageviews can also pulled for months after the original publishing date, e.g. February 2019, March 2019 etc.

How can I pull just the data for a specific month? E.g, in my case I would like to pull data from:

• Where data pull date is January 2018 (Date) and publishing date (Publishing Month) is January 2018 = 65 Pageviews?
• Where data pull date is February 2018 (Date) and publishing date (Publishing Month) is February 2018 = 90 Pageviews?

With my calculation, I get the total number of  Pageviews for 2018 = 110 for articles with a publishing date of January 2018, not the Pageviews for just January 2018 = 65. So my calculation is actually including both January of 2018/2019.

Any help highly appreciated.

• ###### 1. Re: Selecting Pageviews for a specific article/month

Marco,

Do you always want the selected month to be in 2018?  If so just add a date filter to only look at 2018.

Alternatively you can change your formula to be:

IF MONTH([Date]) = [SelectMonth] AND Month([Publishing Month]) = [SelectMonth]

and YEAR([Date]) = 2018 and YEAR([Publishing Month]) = 2018 THEN [Pageviews] END

Depending on your goal you may want to add a way for them to change the year or make you selection parameter a month/year.

Let me know if you have any questions.  See attached.

Thansk,

Scott

• ###### 2. Re: Selecting Pageviews for a specific article/month

Scott,

Thank you so much. This is exactly what I was looking for.

Thanks,

Marco