Closed (won't fix)
Project:
Views (for Drupal 7)
Version:
6.x-2.2
Component:
user data
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
13 Jan 2011 at 16:08 UTC
Updated:
25 Aug 2017 at 10:16 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
oschuetze commentedGreat! This Patch works fine.
Comment #2
dawehnerLooks fine.
Comment #3
javlinsharp commentedI have found this bug in 6.x-2.12, the GA release version as well. However, the patch above is not appropriate for this version and obviously does not work.
Anyway, seems to be a different problem as the patch does a - and + on code I could not find in this version.
Any chances of a backfill?
Error msg
user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' 37, 41, 43, 44, 45, 46, 48, 34, 36) ORDER BY r.name' at line 1 query: SELECT u.uid, u.rid, r.name FROM role r INNER JOIN users_roles u ON u.rid = r.rid WHERE u.uid IN (, 37, 41, 43, 44, 45, 46, 48, 34, 36) ORDER BY r.name in /home/vldevelo/public_html/betadev/sites/all/modules/views/modules/user/views_handler_field_user_roles.inc on line 26.
View Export attached
Comment #4
merlinofchaos commentedPlease generate patches from the views module root.
Committed to D6.x-3.x -- doesn't apply to 7.x, not sure if it needs to.
Comment #5
dawehnerRequires #975400: Refactor field render() functions to accept $value, allowing reuse
Comment #6
bojanz commentedIncluded the fix in #975400: Refactor field render() functions to accept $value, allowing reuse .
Comment #7
thinkinghuman commentedHi, I faced this error again and looked at the file itself (views_handler_field_user_roles.inc ). My file was truncated at line 26. Somehow in the middle of the SQL statement.
What I did is to download this file again from http://drupalcontrib.org/api/drupal/contributions--views--modules--user-...
and replace it.
This is weird. Seems to me like some module wanted to update this file and truncated it.
Best,
Sina
PS: Initially what did not work was that when I wanted to edit my Views in Drupal there was a Javascript error. By tracing it, I came to this file.
Comment #8
bojanz commentedThere's nothing to review here. Good to know you've solved your problem.
Comment #10
Uxi commentedI am still getting an error at line 26 when trying to display roles and the uid is empty (node-based view with -not required- relationship to referenced user and some user(s) is/are not present in a result set of multiple displayed rows).
IMO there should be a test if the result is empty or not in the for each loop at line 20.
This is what I ended up with:
At least that is what works for me.
Unfortunately at this stage I do not know how to submit this here, since I am a total drupal.org newbie, this being my first contribution ever. Still I hope this can help in some way?
Comment #11
dawehnerSee http://drupal.org/node/707484 of a handbook how to create patches.
In general you should try to choose a describing variable name.
Can you update the used views version?
Comment #12
mustanggb commented