Home › Forums › Front-end Issues › Querying relationship fields not working › Reply To: Querying relationship fields not working
That depends on the type of relationship field. A relationship field that only allows 1 selections is stored as the post ID of that selection and then you would query for posts there the value “=” that post ID. A relationship field that allows multiple values is stored as a serialized array and requires the “” around the post ID.
More question:
Are you using guberbug blocks? Is the relationship field a block?
If not the above, is the relationship field a sub field of another field; repeater, group, flexible content?
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.