Help

Counting records between two dates

Topic Labels: Data
Solved
Jump to Solution
540 1
cancel
Showing results for 
Search instead for 
Did you mean: 
adriaurora
5 - Automation Enthusiast
5 - Automation Enthusiast

Hi guys! Thanks in advance for your support.

Right now I have several tables in a database, one of the tables contains the events that occur, and another table contains the types of events that exist (in order to count them). The question is, how can I count only the events that have occurred in a specific month or have been involved in that month? For example, if I want to know the number of events that have occurred in May, but an event started in April and ended in June, it is not going to count if I use a conditional which searchs for event started or ended in May.

Do you have any ideas of how to implement it?

 

1 Solution

Accepted Solutions
Stephen_Orr1
10 - Mercury
10 - Mercury

Hi @adriaurora,

I answered a very similar question recently for @grecol over here so it is still fresh in my mind 🙂

To filter a view for events that occur(ed) anytime during a specific date range, you can use the following filter logic:

Event start date is on or before your chosen range's end date AND Event end date is on or after your chosen range's start date

So to filter for events that were ongoing in May regardless of start/end dates, try:

Event start date is on or before May 31 AND Event end date is on or after May 1

Hope that helps!
-Stephen

See Solution in Thread

1 Reply 1
Stephen_Orr1
10 - Mercury
10 - Mercury

Hi @adriaurora,

I answered a very similar question recently for @grecol over here so it is still fresh in my mind 🙂

To filter a view for events that occur(ed) anytime during a specific date range, you can use the following filter logic:

Event start date is on or before your chosen range's end date AND Event end date is on or after your chosen range's start date

So to filter for events that were ongoing in May regardless of start/end dates, try:

Event start date is on or before May 31 AND Event end date is on or after May 1

Hope that helps!
-Stephen