Skip Navigation

[Resolved] Filter query by Relationship fields in a view on content template

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 1 reply, has 2 voices.

Last updated by Luo Yang 1 year, 9 months ago.

Assisted by: Luo Yang.


Good morning ,
I need to filter the results of a view based on filling in a field.
I created the relationship between two Posts, Companies and Networks. I added custom fields to the report: Join Date and Network Exit Date.
Now, inside the Network tab, I have to show the list of companies that have not entered data in the "date of exit from the network".

This is the page of list hidden link

Thank you



I assume we are talking about this case:
1) Two post types:
- Companies
- Networks

2) Many-to-many relationship between Companies and Networks using intermediate post type "report", with custom fields:
- Join Date
- Network Exit Date

You are going to do this:
In the single "Network" post, display those related Company posts without "Network Exit Date" value

If it is, you can try these:
Create a post view:
1) Query "report" posts
2) Filter by:
- post type relationship between Companies and Networks
- "Network Exit Date" field value is empty
- In view's loop, display related Companies post information

This ticket is now closed. If you're a Toolset client and need related help, please open a new support ticket.