What this module does:

The Reverse Node Reference module enhances Views with "reverse references" for Node Reference fields. In order to use this module you will need a node reference field on a content type referencing another content type as well as Views. The Reverse Node Reference module provides a Views relationship much like Node Reference does but in reverse, from parent to child.

Description:

Node Reference fields in CCK for Drupal 6 provide Relationships to Views that allow you to access fields from the referred nodes of a particular node reference field. These kind of relationships allow you to travel from the child node (the one that has the node reference field) to the parent node (the referred node).

For certain applications, we may also need to do the opposite, travel from the parent node (the referred node) to the child node (the one that has the node reference field). There was a request in the CCK issues to implement these kind of reverse relationships, but it was basically discarded because the discussed approaches 1) had no support for node revisions, or 2) were going to require MySQL 5.1+ or PostgreSQL 7.1+ (due to a requirement for Nested Joins).

This module implements the reverse relationships using the second option, by implementing Nested Joins thus requiring certain database requirements above that of regular Views and CCK. See below for alternatives.

Usage:

This module depends on CCK, CCK Node Reference and Views. After enabling the module:

  • Create a node reference between two content types.
  • Create a view and add a Relationship. You will see a relationship called: "Content: ContentName" and the reverse: "Content reverse references: ContentName"
  • Add filter for the parent content type.
  • Add fields for the parent, such as Node: Title.
  • Add fields from the children that reference the parent. For example, you can add the Node: Title again. But this time use the Relationship you created. You should now see the child titles as well as the parent titles.

Alternatives:

NodeReferrer

NodeReferrer uses a different approach, but may be useful for those who cannot use Reverse Node Reference due to database limitations. The Node Referrer module provides a CCK field that is used to store information about the Node Reference field in another node. It duplicates relationship information, which may be prone to generate inconsistencies. (Read more how it differs from nodereferrer.)

Node Relationships

Do Reverse Node Reference and Node Relationships provide similar functionality?"

No. Each module provides a different set of features that allow you to approach similar problems in different ways. It is all about relations between nodes, but there are several problems here to solve. There is no single module that allows you to solve all your needs about relations between modules, the way users manage them, the ways you display them, etc.

The Reverse Node Reference module is related to the Node Relationships module. The former provides a method to create joins in views that allow you to do things the later cannot do.

Use Cases

To be updated.