Answers.Body: <p>Thanks for the hint ErikH, you led me down the correct path.  We are trying to avoid coding and prefer to just manipulate the views as much as possible.</p>
  
  <p>The view I was working on was a CiviCRM Case view.</p>
  
  <p>I rebuilt it as a CiviCRM Relationship view and added these relationships:
  <img src="https://i.sstatic.net/Lln2c.png" alt="enter image description here"></p>
  
  <p>After that, the Case Coordinators were listed correctly and I was able to add all other pertinent fields to the view.</p>
  
  <p>The fields I displayed were:</p>
  
  <p>Client Name (links to another view of client information)</p>
  
  <p>Case Type</p>
  
  <p>Case Coordinator</p>
  
  <p>Case Status</p>
  
  <p>Case Opened Date</p>
  
  <p>Last Activity Date (turned on aggregation for the view and set only this field to Maximum)</p>
  
  <p>View Case Activities (links to another view of activities filtered by contact id)</p>
  
  <p>Add New Activity (links to a webform for that case type)</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-05T12:19:35.803Z
Answers.LastActivityDate: 2015-06-05T12:24:42.473Z
Answers.LastEditDate: 2015-06-05T12:24:42.473Z
Answers.UserDisplayName: pmoz
Answers.Body: <p>The case coordinator relationship (table civicrm_relationship) will hold the case_id for a case relationship. You should either link to that or retrieve it using the API (if you are coding)</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-05T10:06:01.960Z
Answers.LastActivityDate: 2015-06-05T10:06:01.960Z
Answers.UserDisplayName: ErikH - CiviCooP
Body: <p>We have contacts that may have multiple cases, each with a case coordinator.</p>
  
  <p>I have created a view for each case type that shows the associated case coordinator along with last activity date, links to add activities, etc.</p>
  
  <p>Everything works great except if a contact has multiple cases, the case coordinator from a different case type may be listed instead of this particular case type's case coordinator.</p>
  
  <p>I have a case type filter set to the specific type, but that doesn't seem to be enough.</p>
  
  <p>Here are the relationships:</p>
  
  <p><img src="https://i.sstatic.net/WtoMz.png" alt="enter image description here"></p>
  
  <p>Here are the filters:</p>
  
  <p><img src="https://i.sstatic.net/VMEEt.png" alt="enter image description here"></p>
  
Tags: <civicase><drupal-views>
Title: If contact has multiple cases, how do I filter a view to show only case roles associated to that case type
ThreadText: # If contact has multiple cases, how do I filter a view to show only case roles associated to that case type
  
  (Asked by: username_0 on 2015-06-04)
  
  We have contacts that may have multiple cases, each with a case coordinator.
  
  I have created a view for each case type that shows the associated case coordinator along with last activity date, links to add activities, etc.
  
  Everything works great except if a contact has multiple cases, the case coordinator from a different case type may be listed instead of this particular case type's case coordinator.
  
  I have a case type filter set to the specific type, but that doesn't seem to be enough.
  
  Here are the relationships:
  
  ![enter image description here](https://i.sstatic.net/WtoMz.png)
  
  Here are the filters:
  
  ![enter image description here](https://i.sstatic.net/VMEEt.png)
  
  **Tags:** civicase, drupal-views
  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_0 on 2015-06-05. Score: 2 | Accepted answer
  
  Thanks for the hint username_1, you led me down the correct path. We are trying to avoid coding and prefer to just manipulate the views as much as possible.
  
  The view I was working on was a CiviCRM Case view.
  
  I rebuilt it as a CiviCRM Relationship view and added these relationships:
  ![enter image description here](https://i.sstatic.net/Lln2c.png)
  
  After that, the Case Coordinators were listed correctly and I was able to add all other pertinent fields to the view.
  
  The fields I displayed were:
  
  Client Name (links to another view of client information)
  
  Case Type
  
  Case Coordinator
  
  Case Status
  
  Case Opened Date
  
  Last Activity Date (turned on aggregation for the view and set only this field to Maximum)
  
  View Case Activities (links to another view of activities filtered by contact id)
  
  Add New Activity (links to a webform for that case type)
  
  
  ---
  
  ### Answer by username_1 on 2015-06-05. Score: 1
  
  The case coordinator relationship (table civicrm\_relationship) will hold the case\_id for a case relationship. You should either link to that or retrieve it using the API (if you are coding)
  
  
  ---
  
  