Learn about our newest features and enhancements!
Queries: What Can I Do with a Query: Donations Within X Days
Jessica Mocha 11/18/2022 12:30:00 PM

A great
use of the query tool is monitoring the donations within a time frame. This will provide a deeper look into who is donating and how much they are donating. This can also be used to send out communications to recent donors inviting them to events, thanking them for their contribution, or sending them updates on the campaign they donated to.

To set this query up, you will need to be in the Transaction Database under the Donations filter.

To get started, navigate to Automation & Workflow > General > Queries > Create New. Then select Donations table under Filter and select Transactions and Continue.

The first filter you will want to add is the date filter to set the time frame the database will pull from

To set the filter to pull information within 2 years, click on the formula button and choose “Last X Days from the drop-down.

You will now be able to enter the number of days you want the database to pull from, 2 years would be 730 days.

Note: The drop-down does have relative date options to select out of the box, such as yesterday, last month, or year to date, however, if the date range is not listed, the Last X Days formula will allow you insert the range you are looking for, like 730 days (2 years).

The next selection you will add is the Contact ID, you will want to select group by to list each contact only once in the query.

Note: you can group by contact name, however grouping by ID is more efficient

Next, add payment amount to the select field and set the formula to Sum

Click the filter button to add the selection to the filter

You will now be able to set the filter to only search the database for donations of a certain amount. For example, if you only want to see those who have donated $100.00 or more, you would select Greater Than or Equal to in the drop-down and enter $100.00 in the value

If you would like to see how many donations a contact has made, add the transaction ID and set the formula to Count

Now you will be able to click the Run button and the query will pull all contacts who have donated $100.00 or more in the last 730 days. Each contact ID will only be listed once and you will be able to see how many donations they have made.

Related Articles

Powered by Powered By CharityEngine