Skip Navigation

[Resolved] Is there any reason *not* to create redundant or circular relationships?

This support ticket is created 5 years, 5 months ago. There's a good chance that you are reading advice that it now obsolete.

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
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10: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/Kolkata (GMT+05:30)

Author
Posts
#1131243
SE-xSH.jpg

See diagram for reference.

Each State belongs to a State Group, and a Set is a transformation from a "before" State Group to an "after" State Group. Each State undergoes its own specific transformation from before to after. I want to display a list of State transformations, showing State before and State after each Shift, on a Set single post. To do so, I've created the intermediary post type Shift, linking the State before to the State after.

To provide the most direct route to this display I've created a one-to-many relationship between Set and Shifts. I'm wondering if this circularity, where you can get to any given State through several different relationship conjunctions, presents a problem. I'm not experienced in databases and am wanting to double check to make sure I'm not doing something that could create a problem down the line.

Thanks in advance for your help.

#1132154

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Well - in this case, to help you further we need actual data and structure that will help us to understand exactly at which part holds information and which data you want to normalize.

Having said that, I suggest first you should consult some database expert and then use one of our reference sites on discover-wp.com where you should create your test relationship and play with it that will help you to understand your data flow and structure using post-relationship and doing that I think that will help you to understand what relationships you need indeed and which are redundant.

More info:
=> https://toolset.com/faq/how-and-why-to-create-a-test-site-in-discover-wp/

Once you have actual data and information which part holds what information we will be in a better position to guide you further and in the right direction.

#1132253
PostType-Relationship Schema.jpg

Perhaps it would be best for me to give you access to a dev staging installation of my site, where all this is actually fairly built out so far. There's no way for me to reproduce that in Discover-WP because there is no WP import functionality, and it's too involved to set up again by hand.

Here is a page on that installation on which I inserted a view displaying the list of States connected by Shifts as described above: hidden link. I've gone into a little more depth about how I set up that page on this other recent ticket (https://toolset.com/forums/topic/bootstrap-columns-are-stacking-vertically-instead-of-laying-out-horizontally/) where I was having Bootstrap problems on the display.

I am also attaching a graphic of the full schema for post types and relationships.

#1132599

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

So could you please share access with me and tell me what exactly you want to do or to which part you are looking for improvements with which relationship with problem URL?

I have set the next reply to private which means only you and I have access to it.

#1133828

Thank you Minesh. I think I'll need to just move forward and build out more of the site with the various post layouts to illustrate what I'm after. There is no specific problem now, and things are working out fine so far. I was just wanting to anticipate possible things to avoid in the future. I'll get back to you all when things are ready for that evaluation, and close the ticket for now.

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