Calculated Field- Sum of Costs

How do I create a calculated field to get the sum of costs for a date range?

Hello @jennifer.dankovic, welcome to the Quick Community!

You can do this a few different ways. If you are applying a date range filter, you honestly might not need a calculated field at all. Just filter the visual to the date period and you can add the costs field to the visual and set it to sum.

Otherwise, you could write an ifelse statement to only return cost when it is between the 2 dates. If you are setting parameters with date values, that would look like this:

ifelse({date} >= ${StartDate} AND {date} <= ${EndDate}, {costs}, NULL)

Let me know if that helps!