Hello,
if I click on the column header for the username column in the table view of the results, I get the following error:
PDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'name' in 'order clause': SELECT ws.sid AS sid FROM {webform_submissions} ws WHERE (nid = :db_condition_placeholder_0) ORDER BY name ASC LIMIT 50 OFFSET 0; Array ( [:db_condition_placeholder_0] => 36 ) in PagerDefault->execute() (Zeile 79 von /is/htdocs/*****/www/includes/pager.inc).
All other colums are working, but the username column doesn't.
Is this a known bug? do you have any recommendations?
Thanks,
Basti
Comment | File | Size | Author |
---|---|---|---|
#4 | webform_sort_username.patch | 571 bytes | quicksketch |
Comments
Comment #1
quicksketchThanks for the report. I think this is the first report of this bug, but it's something we've encountered in the past. I'll look into it.
Comment #2
quicksketchMarked #1570590: Unexpected error when sorting by user duplicate.
Comment #3
quicksketchThe related issue that I was thinking of was #1074326: PDOException: SQLSTATE[23000] -- when viewing submissions . So this is definitely a separate problem that hasn't been addressed before.
Comment #4
quicksketchI've committed this patch to correct the issue. This patch may unnecessarily join the user table even if the "name" or "uid" column is not necessary, but at the same time we only pass in the $header variable on this page alone, so it's not going to affect any other places in the core module. Other places where you'd likely pass in a $header would also want the user table anyway, so I don't think this is an unfair compromise. In any case, fixes the immediate problem.
Comment #5
quicksketchComment #6
kiwimind CreditAttribution: kiwimind commentedI can confirm that this patch works fine against 7.x-3.17.
Thanks very much.