Hi there,
Just upgraded to the latest version and noticed the following:
I have 2 custom content types:
- Team (contains a cck text field with the team name)
- Game
The 'Game' content type has two cck node reference fields:
- Home: points to a team
- Away: also points to a team
I tried creating a view that shows all games for a team. In order to display the home and away team names, I added 2 relationships with different labels. I then added two fields using these relationships. Unfortunately, the view displays the same team name twice, so it seems to be using only 1 of the relationships. If I reorder the relationships, the team names change to the name of the first relationship.
I noticed a similar type of issue that has been created earlier, but should've been fixed: http://drupal.org/node/286553
Any idea if:
- I'm doing something wrong?
- This is a limitation of Views?
- This is a bug?
Cheers!
Joris
Comments
Comment #1
dawehnerits incredible hard to help you if you don't export your view, because i can't guess whether you did something wrong or not
Comment #2
osieke commentedHere you go:
Comment #3
osieke commentedAnd here's the SQL:
SELECT node.nid AS nid, node_data_field_wedstrijd_datum.field_wedstrijd_datum_value AS node_data_field_wedstrijd_datum_field_wedstrijd_datum_value, node.type AS node_type, node.vid AS node_vid, node_data_field_ploeg_naam.field_ploeg_naam_value AS node_data_field_ploeg_naam_field_ploeg_naam_value, node_node_data_field_wedstrijd_thuis.nid AS node_node_data_field_wedstrijd_thuis_nid, node_node_data_field_wedstrijd_thuis.type AS node_node_data_field_wedstrijd_thuis_type, node_node_data_field_wedstrijd_thuis.vid AS node_node_data_field_wedstrijd_thuis_vid, node_node_data_field_wedstrijd_bezoekers.nid AS node_node_data_field_wedstrijd_bezoekers_nid, node_node_data_field_wedstrijd_bezoekers.type AS node_node_data_field_wedstrijd_bezoekers_type, node_node_data_field_wedstrijd_bezoekers.vid AS node_node_data_field_wedstrijd_bezoekers_vid FROM node node LEFT JOIN content_type_wedstrijd node_data_field_wedstrijd_thuis ON node.vid = node_data_field_wedstrijd_thuis.vid LEFT JOIN node node_node_data_field_wedstrijd_thuis ON node_data_field_wedstrijd_thuis.field_wedstrijd_thuis_nid = node_node_data_field_wedstrijd_thuis.nid LEFT JOIN content_type_wedstrijd node_data_field_wedstrijd_bezoekers ON node.vid = node_data_field_wedstrijd_bezoekers.vid INNER JOIN node node_node_data_field_wedstrijd_bezoekers ON node_data_field_wedstrijd_bezoekers.field_wedstrijd_bezoekers_nid = node_node_data_field_wedstrijd_bezoekers.nid INNER JOIN term_node term_node_value_0 ON node.vid = term_node_value_0.vid AND term_node_value_0.tid = 4 INNER JOIN term_node term_node_value_1 ON node.vid = term_node_value_1.vid AND term_node_value_1.tid = 9 LEFT JOIN content_type_wedstrijd node_data_field_wedstrijd_datum ON node.vid = node_data_field_wedstrijd_datum.vid LEFT JOIN content_type_ploeg node_data_field_ploeg_naam ON node_node_data_field_wedstrijd_thuis.vid = node_data_field_ploeg_naam.vid WHERE (node.status <> 0) AND (node.type in ('wedstrijd')) AND (term_node_value_0.tid = 4 AND term_node_value_1.tid = 9)Comment #4
merlinofchaos commentedDoes quicksketch's patch in http://drupal.org/node/317271#comment-1459264 fix this?
Comment #5
osieke commentedYes it does! Thank you very much for your support. Is this something that might get incorporated into views?
Comment #6
merlinofchaos commentedIt will be in 2.6. (I just released 2.5 and didn't get this one in, but with the patch available you can run a patch version until 2.6 is out)