I have a view to list the Voucher content type. I added a filter: Configure filter criterion: Content: Voucher codes (field_voucher_code) NOT EMPTY.

The idea is to show the node only if its field field_voucher_code is not empty

The field_voucher_code is field which has set the Number of values to 10 at admin/structure/types/manage/vouchers/fields/field_voucher_code

The problem is that the view is duplicating each as many time as values has in its field field_voucher_code.

How can I eliminate the duplicates?

1 Answer 1


You can do this by enabling Aggregation or set distinct in Query settings

  1. Go to your View->Advanced->Use Aggregation -> set YES
  2. Next in your field filter criteria chose - Count DISTINCT

One more way - 1. Go to your View->Advanced->Query Settings -> check DISTINCT

  • Aggregation didn't work, but I get it working fine withView->Advanced->Query Settings -> check DISTINCT. Thanks
    – chefnelone
    Feb 7, 2013 at 18:16

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.