3

Is there any way to get a report, ideally something like the Contribution Summary report, which allows you to filter by recurring or non-recurring contribution?

It would be quite useful to be able to get a report of all the donors who gave more than $XXX last year, but exclude recurring contributions. There are reports that will show only recurring donations, but I can't seem to find anything in reports that allows me to exclude recurring donations (obviously, this is easily done in contribution search, but that doesn't let me find aggregate contributions over the year).

If this isn't currently possible, is it as simple as looking for donations with an empty or not-empty recurring contribution ID?

2
  • Are you on drupal or wordpress? Jan 27, 2020 at 18:07
  • We're on Drupal
    – Lars SG
    Jan 27, 2020 at 22:58

3 Answers 3

4

ReportPlus (https://civicrm.org/extensions/reportplus) is worth looking at.

The included template report for 'Contribution Matrix Plus' definitely has a filter for 'Contribution is Recurring? - Any, Yes, No' already and I suspect some of the other templates will do too.

3

Eileen's Extended Reports extension has contribution reports that may help. In the latest version ('master' branch, not yet officially released), Jon added a display field "Recurring Donation?" that can be selected under the 'Columns' tab. At first glance, it doesn't seem to be possible to filter using that option, but you could export all the results and then filter using your favourite spreadsheet software.

Contribution report columns

The Donation Summary report does not have a column/filter available, but looking at Jon's patch here, it should be relatively easy to add?

In other words, a non-recurring contribution has an empty "recurring contribution ID", but it would be great to improve reports in general.

1
  • It is now possible to filter in Extended Reports by choosing Recurring Payments are not null or are null to include only or exclude recurring payments. And I've submitted some code to put this into core.
    – Lars SG
    Apr 27, 2021 at 22:24
2

There are no such report that filters based on if contribution is recurring or not. As said by bgm if you are developer than you can use hook_civicrm_alterReportVar() hook or send a PR to core to add contribution recur filter on contribution report. Since you are using Drupal CMS you can create your own report using Views module. The views integration provide lots of filtering and fields selection and also you can export the results by installing relevant modules.

An example of simple view which displays contribution id having recurring.

$view = new view();
$view->name = 'contr';
$view->description = '';
$view->tag = 'default';
$view->base_table = 'civicrm_contribution';
$view->human_name = 'contr';
$view->core = 7;
$view->api_version = '3.0';
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */

/* Display: Master */
$handler = $view->new_display('default', 'Master', 'default');
$handler->display->display_options['title'] = 'contr';
$handler->display->display_options['use_more_always'] = FALSE;
$handler->display->display_options['access']['type'] = 'none';
$handler->display->display_options['cache']['type'] = 'none';
$handler->display->display_options['query']['type'] = 'views_query';
$handler->display->display_options['exposed_form']['type'] = 'basic';
$handler->display->display_options['pager']['type'] = 'full';
$handler->display->display_options['pager']['options']['items_per_page'] = '10';
$handler->display->display_options['style_plugin'] = 'default';
$handler->display->display_options['row_plugin'] = 'fields';
/* Field: CiviCRM Contributions: Contribution ID */
$handler->display->display_options['fields']['id']['id'] = 'id';
$handler->display->display_options['fields']['id']['table'] = 'civicrm_contribution';
$handler->display->display_options['fields']['id']['field'] = 'id';
/* Filter criterion: CiviCRM  Recurring Contributions: Recurring Contribution ID */
$handler->display->display_options['filters']['id']['id'] = 'id';
$handler->display->display_options['filters']['id']['table'] = 'civicrm_contribution_recur';
$handler->display->display_options['filters']['id']['field'] = 'id';
$handler->display->display_options['filters']['id']['operator'] = 'not empty';

/* Display: Page */
$handler = $view->new_display('page', 'Page', 'page');
$handler->display->display_options['path'] = 'contr';
$translatables['contr'] = array(
  t('Master'),
  t('contr'),
  t('more'),
  t('Apply'),
  t('Reset'),
  t('Sort by'),
  t('Asc'),
  t('Desc'),
  t('Items per page'),
  t('- All -'),
  t('Offset'),
  t('« first'),
  t('‹ previous'),
  t('next ›'),
  t('last »'),
  t('Contribution ID'),
  t('.'),
  t(','),
  t('Page'),
);

Thanks

Pradeep

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.