Views integration with the relation module
Introduction
Relations is an awesome new module for Drupal 7. It essentially allows you to link any entities together and which are themselves fieldable. I can think of limitless ways in which this can be super useful. However, the topic of this blog posting is not to heap praise on relations and explain in detail what they can be used for; I'll let you discover that yourselves. The intention is rather to give a practical example of how to create views of separate entity types tied together with relations. Something that I've had to play around with for hours to figure out. Perhaps this will save you some time.
Note: At the time of writing this the functionality I'm discussing only exists in the dev release of relation. Beta3 does contain this. If people from the future are reading this blog the functionality was commited Jan 21st by chx.
An Example relation
Just read about this example on the d.o. issue queue where someone needed help with the views integration. So, lets say we create a relation that defines a relationship between a user and nodes called 'follow'. So that is to say a user can select particular nodes they deem interesting and choose to follow them.
Note: This could be accomplished other ways as well such as using the flags module, but we'll ignore that for now and consider that a relation can probably give us more functionality.
We add a field to the 'follow' relation called 'category' to categorize the nodes which the user is following.
So now what we have is a directional relation user -> node with the single field 'category'.


I do think that 

OpenConcept has been donating books to the Ottawa Public Library for a couple years now, and so last fall I ordered a bunch of Drupal 7 books anticipating that we'd review them within our team & then order new ones to the library had a fresh copy. I ordered my copy of the