In umbraco we have ability to create relations via the gui when copying content nodes, other relations can be made through the api.
We also have numerous datatypes that allow users to create related links between content and media. So does this not make relations redundant? Basically creating this post to get better understanding of where relations fit into the bigger umbraco picture.
We are using the copy relations (API) to handle translation workflows. This makes sense since it is easy to find child relations of the original node at and send those to translation.
I think the relations API is a cleaner way of doing relations than using multiple content pickers and suchm since I do not need to get properties from the nodes, and start splitting comma separated strings and such. It is also much easier to make two way relations with the API.
The relationship datatypes are only one way relationships, so the child item is unaware its connected to it's parent object.
If you need a 2 way, 1 to many or many to many relationship then it's impossible to do with the XML/CSV datatypes. This is where Relationships come in you can manage the connection to objects from both sides ie the child is aware of the parent as well as the parent knowing about the child.
Hope that helps. If you want me to go in to more detail give me a shout.
Relations are *real* relations, where as the Related links data type is simply a list of related nodes but it's "dumb" one since there's no programmatic way of accessing this information.
The relation api on the other hand makes it possible to relate almost all types of Umbraco objects to each other and make the relation either one way or two way. This is used on this site for the "Events" section for instance. When you sign up for an event a relation is made between you (a Member) and an event (a Node). This way we can use the Relation API (and its xslt helper methods) to query information on attendees, but we could also easily show all events that you either are coming to or have been to using the same API.
We'll cover this in details in a chapter on umbraco.tv later this quarter.
Relations vs related links
Guys,
In umbraco we have ability to create relations via the gui when copying content nodes, other relations can be made through the api.
We also have numerous datatypes that allow users to create related links between content and media. So does this not make relations redundant? Basically creating this post to get better understanding of where relations fit into the bigger umbraco picture.
Regards
Ismail
We are using the copy relations (API) to handle translation workflows. This makes sense since it is easy to find child relations of the original node at and send those to translation.
I think the relations API is a cleaner way of doing relations than using multiple content pickers and suchm since I do not need to get properties from the nodes, and start splitting comma separated strings and such. It is also much easier to make two way relations with the API.
Hi Ismail
The relationship datatypes are only one way relationships, so the child item is unaware its connected to it's parent object.
If you need a 2 way, 1 to many or many to many relationship then it's impossible to do with the XML/CSV datatypes. This is where Relationships come in you can manage the connection to objects from both sides ie the child is aware of the parent as well as the parent knowing about the child.
Hope that helps. If you want me to go in to more detail give me a shout.
Jon
Relations are *real* relations, where as the Related links data type is simply a list of related nodes but it's "dumb" one since there's no programmatic way of accessing this information.
The relation api on the other hand makes it possible to relate almost all types of Umbraco objects to each other and make the relation either one way or two way. This is used on this site for the "Events" section for instance. When you sign up for an event a relation is made between you (a Member) and an event (a Node). This way we can use the Relation API (and its xslt helper methods) to query information on attendees, but we could also easily show all events that you either are coming to or have been to using the same API.
We'll cover this in details in a chapter on umbraco.tv later this quarter.
Niels...
Guys,
Awesome many thanks, its the 2 way thing that has given me the light bulb moment.
Regards
Ismail
is working on a reply...