This is a View querying Users. When I add a Relationship to User: Webform submission, in order to add a view link to the table of users and their webform submissions, I get:
user warning: Unknown column 'users.webform_submission' in 'on clause' query: SELECT users.uid AS uid, users.name AS users_name FROM users users LEFT JOIN webform_submissions webform_submissions_users ON users.webform_submission = webform_submissions_users.uid LIMIT 0, 10 in /yoursitenamehere/sites/all/modules/views/includes/view.inc on line 810.
If this should be an issue on the Views module instead, let me know and I will put it there.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | webform.views_.inc_.patch | 802 bytes | nilo |
Comments
Comment #1
quicksketchThanks, this request does indeed belong here. This sounds very similar to #1435846: View ajax error when adding a submission link handled by webform_handler_field_submission_link via a relationship, but is probably a different problem. The solution is probably similar though. We just need to manually specify the relationship in our hook_views_data_alter().
Comment #2
nilo commentedFor the "Webform submission of user." relationship the wrong field was being referenced in the users table.
Should be:
$data['users']['uid'] = array(instead of:
$data['users']['webform_submission'] = array(on line 211.
Patch file attached.
Comment #3
danchadwick commentedThe 6.x branch is receiving critical bug fixes only.