So here is what I am trying to figure out how to do. I have a content type of Users and I have a content type of User Programs (Outreach Program, Coaching Program, AA Program, etc) these are being linked by the Entity Reference module as a field on the User content type.

So when I am editing a User, I select the different programs that user is linked to (via the Entity Reference Module). The User Programs content type has taxonomy for the different program categories (Central Sector, North Sector, Western Sector, etc) and you can select multiple categories on the User Programs Node.

What I want to do in Views is this:

 Contextual filter: (User NID) = 40

 User: John Doe

 Programs Related to User --

   Central Sector (Taxonomy) -
     Outreach Program

   North Sector (Taxonomy) -
     Coaching Program
     AA Program

I know how to do simple views, but this one is starting to go out of my comfort zone, and I am getting kind of confused on how I could do something like this. I've tried an EVA view, but I am not too sure if that's what I am supposed to use. Any help would be greatly appreciated!


2 Answers 2

  1. Create your View looking at User records.
  2. Add a Relationship under the Advanced section to link to your Taxonomy.
  3. You then may have to use some Grouping, or Aggregation

Does that help?

  • I am trying to work with it right now, but it's duplicating a node 5 times... But this actually may be something. I'll work on it some more and post back some results..
    – Aaron Olin
    Feb 19, 2013 at 1:39
  • I assume that could be the expected result if the User has 5 Taxonomy items. If that is correct, give Grouping a try.
    – user5681
    Feb 19, 2013 at 2:10
  • I ended up using entity relationships, and I was able to pull the taxonomy from the referenced content type. Kind of hard to explain, but I was finally able to then group by taxonomy, and the list the contents under each taxonomy... phew! It was a jungle out there! Thanks for your help ForeverDebugging!
    – Aaron Olin
    Feb 26, 2013 at 2:45

Thanks for the tip with the Aggregation method. I am trying it right now, but the User is getting duplicated a few times, so I have to figure out how to limit that, but I think we're on the right track.

I am trying to simplify this by just doing a vanilla drupal view with Articles being the main query, and querying basic pages, and getting taxonomy terms from the basic pages.

Article 1 -
 Basic Page 1
  page tax 1
  page tax 2
  page tax 3

 Basic Page 2
  page tax a
  page tax b

Article 2 -
 Basic Page 1
  page tax I
  page tax II
  page tax III

 Basic Page 2
  page tax 1
  page tax 2

Seems like a weird query I know, but I am trying to simplify this process

  • This is what I wanted to post up last night, but it wouldn't let me... But the diagram above is what I am trying to result in.
    – Aaron Olin
    Feb 19, 2013 at 14:52

Your Answer

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

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