Hi im trying to make a node view and on it display the last commentators user picture. Ive added relationhip Comment User and then in the user image field ive used that relationship. As you can see here though i have an entry for every comment on the post.
http://img713.imageshack.us/img713/443/viewc.jpg
http://img832.imageshack.us/img832/3886/viewoutput.jpg
Ive tried using distinct etc without any effect. Is there a way to do this?
Thanks
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | 1301366.patch | 954 bytes | dawehner |
Comments
Comment #1
dawehnerWell you have a relationship for the last comment author availible. Then get the user: picture by adding a user: picture field with the last comment author relationship.
Comment #2
fadgadget commentedThanks for the reply dereine. I do have the relationship added you mention. the 'Comment: User
The User ID of the comment's author.' then the "User: Picture The user's picture, if allowed." field is added using the relationship added. As you can see from the 2nd screenshot above all i get is a load of entries from the same node. I have to admit dereine i have no idea why i cant get the desired output as it does all make sense to me and i think i have done it right.
Comment #3
dawehnerOh! there is no relationship available, sorry for assuming this.
Feel free to test the patch.
Comment #4
fadgadget commentedThanks for your help dereine your patch worked great. I now have a "Node: Last comment author" relationship and all my views work just as i had hoped. Thanks again.
Comment #5
Letharion commentedComment #6
fadgadget commentedHi Dereine. I hope you dont mind me asking here. Ive had to revert back to views 2 due to a new theme i have on my site. Im having problems with the code when adding it to my new file. Would it be differant code for Views 2?
thanks
Comment #7
dawehnerNo it won't be but this patch will not be added to views2.
Comment #8
dawehnerCommited to both 7.x-3.x and 6.x-3.x
Comment #10
David_Rothstein commentedThe field introduced here seems broken... I filed an issue about it here: #1443244: "Content: Last comment uid" field is broken (fatal error)