2

I have a content type what is news, the news has a field type that is List (text) to keep different types of news. for example I have Health, Sport, Economic and etc.

So now I am going to create a block and have each of these type in that as a hyperlink.

I can do it and I created a new view block but each news_type may showing more than one time according to published content.

How to set the view (for block) to just show news_types and show them just one time?

2 Answers 2

4

You can achieve this by following the steps given below:

  1. Enable aggregation under Advanced Accordion of the view
  2. Add Nid field & set aggregation type as Count Distinct
  3. Exclude Nid field from display
  4. Add news type field & set Aggregation type as Group results together, in Group Column select Value option from dropdown
  5. Remove Publishing Date from sort criteria

Please check attached screenshot for reference

enter image description here

and for more information you can check this question

0
3

You can set Distinct in the advanced settings of your view. A distinct will only show unique records. So if you have a list of all Lists then it will show all unique values of List

1
  • Thanks man, But the other answer by @VishalPatil was better. Thanks anyway :)
    – user44925
    Mar 10, 2015 at 9:31

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.