Relations between nodes in umbraco.. Options
jesperw
Posted: Thursday, December 06, 2007 4:29:28 PM
Rank: Enthusiast

Joined: 9/6/2007
Posts: 10
This is my problem:
I have a bunch of members in umbraco, i need to put a variety of relations between the members: friends, cousins, married or whatever.
(Many to many)

I need to classify content nodes (one content node needs to be able to belong to multiple keywords). The keywords should be administrated in the Umbraco editor by content writers.
(One to many)

Requirements:
To make this fast rendering this information (I want to avoid loading user controls if not needed) therefore I want the solution to be accessible from xslt aswell as usercontrols. There is a demand for searching by relation types between members and keywords for nodes.

Solution1: Create nodes that has two nodeids properties pointing to the realting nodes. I can easily extend the information about the relation by adding properties for relation type, etc. to this datatype. I could store these nodes in a separete "system-container"-node since I don't article writers etc. can't access and wont be distracted by. A simple xpath expression can find these relations fast.

Solution2: Create a property that has a comma separated list with the node ids relating the actual node. Adding extended relation information to this could be done by adding another comma separated property. Finding the nodeids from XSLT will require some string-parsing and will probably be slow on a big umbraco-node-tree.

Solution3: Adding a table with columns representing the relating nodeids and extended information. This will require calls to the SQL Server (require a user control) when locating the relations and will not be available from xslt.

Any suggestions?

Cheers
/ Jesper Wigelius
drobar
Posted: Thursday, December 06, 2007 6:10:10 PM

Rank: Umbracoholic

Joined: 9/8/2006
Posts: 1,698
Location: KY, USA
This might not be a complete solution to your question, but it will go a long way toward creating many-many relationships between content nodes, which will be accessible via XSLT and user controls (because it is a doctype property).

Multiple Content Picker (aka, Multiple page picker via source)
http://www.cpalm.dk/blog/2006/03/29/multiplepagepickerviasource.aspx
Updated by Morten, June 2007:
http://www.mortenbock.dk/updated-cpalm-multiple-page-picker-for-v3-bugfix-57.htm
Updated by Ismail, August 2007:
http://ismail.umbraco.net/2007/8/31/update-to-multiplepagepickerviasource.aspx

cheers,
doug.

MVP 2007-2009 - Official Umbraco Trainer for North America - Percipient Studios
jesperw
Posted: Friday, December 07, 2007 3:13:17 PM
Rank: Enthusiast

Joined: 9/6/2007
Posts: 10
Thank you Douglas!

I'm looking in to that as we speak. The suggested solution would work just fine for the situations where a one to many relation without extended attributes is needed (ie. putting relations between content nodes and keywords).

I will continue this thread as I have a solution to the many to many relation.

Cheers
/ Jesper Wigelius
Users browsing this topic
Guest


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.