I have a view made up of nodes that include node reference fields. I would like to pull in a field from each of the nodes being referenced for display in my view.
I know that is a little confusing so let me give you an example.
- My food content type contains the name of a food and the number of calories it has.
- My diary content type contains a date and a node reference that accepts food nodes.
- My view displays your diary nodes.
- I would like to display the calories for each food item that is being referenced by diary
- I would like to add the calories using views_calc (or something else).
The way I see it there are two ways to do this - either add a calories field to my diary content type that automatically pulls from the node that is being referenced, thus making it available to my view. The other option is for views to be able to pull in fields (sub-fields?) from a node reference field.
I don't know if either option is possible or, if it is, how I would go about doing it. Any help would be greatly appreciated.
Edit: Relationships will allow me to pull in the fields I need, so now I just need a way to add them. Views_calc does not support calculations on relationship fields.