Reverse multi-reference fields?

I keep getting excited about the multi-reference and then realizing that I don’t think it is capable of some really basic stuff. Can someone tell me if you can do a reverse of the multi-reference field? I’ll explain what I’m trying to accomplish…

I have a list of state legislation, and each bill has a number of provisions that could relate to clean energy, water quality, stormwater regulation, etc. These provisions are multi-reference fields. In the bill page, I can list the multi-reference, but I would love to be able to then have a way for my user to click on the provision, be taken to the provision page, and see all the bills that relate to that provision.

Is this possible and I just can’t figure it out? Or no? Seems like it would be pretty basic in terms of letting the user explore these multi-reference categories.

Thanks!

(also multi-reference within category lists for the homepage OMG PLEASE :slight_smile: )

https://preview.webflow.com/preview/killthebill?preview=1cf62348ad758e4a8f3067d3d7750145


Here is my public share link: https://preview.webflow.com/preview/killthebill?preview=1cf62348ad758e4a8f3067d3d7750145
(how to access public share link)

4 Likes

Did you ever solve this?

I’m also looking for a solution to this

I also want a solution to this!

Anything? Beuller? Beuller? Beuller? I could use some help here.

I think I’ve almost done it. If you hit that switch button next to the direction buttons in Flex-Box then it will reverse the order. The only issue is it’s not great at scrolling now… any thoughts?

Screen Shot 2021-09-17 at 12.06.06 AM

Note You have to do this on the LIST object for it to reverse the order of your collection items.

Go to my members template page to see this
Read Only Link: Webflow - Clair Music

Did anyone ever solve this?

The Webflow CMS appears to be based on a key-value document database like MongoDB, rather than a relational database, so there is no way to reverse the multiref field. It’s not a relational datastore.

What you can do, depending on your use case, is to create an xrefs table. Here’s an example;

  • Movies collection contains details about your movies
  • Actors collection contains details about your actors
  • MoviesActorsXref collection contains a single-ref to Movies, a single-ref to Actors, and other relation-specific fields like role, character name, awards…

Now, on your Movies collection page, you can include a collection list bound to MoviesActorsXref, which is filtered to Current Movie. You easily show all of the actors that are in that movie, and the ref lets you pull specific Actor record fields.

On your Actors collection page, you can include a collection list bound to MoviesActorsXref, which is filtered to Current Actor. You can easily show all of the movies that this actor was in, and the ref allows you to pull specific Movie record fields.

In the right situation, this works perfectly. However the data admin is a bit more grunty.

1 Like

This is exactly the information I needed. Thanks!

1 Like

Very nice! You have essentially done database normalization, which is a standard practice when designing SQL database tables.

In a limited fashion. Webflow is based on some variant of MongoDB so it’s not relational at its core, which is why refs are one way and have other weird structural characteristics.

But yes, this is essentially a technique for adding some relational-type patterns on top of the CMS frameworks that aligns pretty well with the Collection Page navigation design.