Skip to main content
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
added 2 characters in body
Source Link
Collins
  • 2.4k
  • 15
  • 28

I use Views in every project, and its not that often that I run into a use case like this any more.

In the set up below, I have a Content type with two field collection fields (day guest and evening guest). I want to display the results of both field collection fields on the node, in the same view.

Both field collections share an "E-mail" field, and when a user enters their e-mail field, I want them to see their results, whether they have been added as a day guest, or an evening guest.

Here's the setup... enter image description here

When I remove one of the two Contextual filters, the results show for the remaining field, and vice versa. But when both Contextual filters are added, I get no results.

Is there a way to do an AND or OR for Contextual filters?

Or in the Contextual filter options, a way to add multiple relationships like below?

enter image description here

While I know this is not possible in the default behavioubehaviour, it is a good example of what imi'm trying to achieve, perhaps someone knows a decent workaround to the issue?

I use Views in every project, and its not that often that I run into a use case like this any more.

In the set up below, I have a Content type with two field collection fields (day guest and evening guest). I want to display the results of both field collection fields on the node, in the same view.

Both field collections share an "E-mail" field, and when a user enters their e-mail field, I want them to see their results, whether they have been added as a day guest, or an evening guest.

Here's the setup... enter image description here

When I remove one of the two Contextual filters, the results show for the remaining field, and vice versa. But when both Contextual filters are added, I get no results.

Is there a way to do an AND or OR for Contextual filters?

Or in the Contextual filter options, a way to add multiple relationships like below?

enter image description here

While I know this is not possible in the default behaviou, it is a good example of what im trying to achieve, perhaps someone knows a decent workaround to the issue?

I use Views in every project, and its not that often that I run into a use case like this any more.

In the set up below, I have a Content type with two field collection fields (day guest and evening guest). I want to display the results of both field collection fields on the node, in the same view.

Both field collections share an "E-mail" field, and when a user enters their e-mail field, I want them to see their results, whether they have been added as a day guest, or an evening guest.

Here's the setup... enter image description here

When I remove one of the two Contextual filters, the results show for the remaining field, and vice versa. But when both Contextual filters are added, I get no results.

Is there a way to do an AND or OR for Contextual filters?

Or in the Contextual filter options, a way to add multiple relationships like below?

enter image description here

While I know this is not possible in the default behaviour, it is a good example of what i'm trying to achieve, perhaps someone knows a decent workaround to the issue?

Source Link
Collins
  • 2.4k
  • 15
  • 28

Multiple relationships in Views Contextual Filters

I use Views in every project, and its not that often that I run into a use case like this any more.

In the set up below, I have a Content type with two field collection fields (day guest and evening guest). I want to display the results of both field collection fields on the node, in the same view.

Both field collections share an "E-mail" field, and when a user enters their e-mail field, I want them to see their results, whether they have been added as a day guest, or an evening guest.

Here's the setup... enter image description here

When I remove one of the two Contextual filters, the results show for the remaining field, and vice versa. But when both Contextual filters are added, I get no results.

Is there a way to do an AND or OR for Contextual filters?

Or in the Contextual filter options, a way to add multiple relationships like below?

enter image description here

While I know this is not possible in the default behaviou, it is a good example of what im trying to achieve, perhaps someone knows a decent workaround to the issue?