Sadler
Member
Hi,
I am trying to show a list of users (usernames) in a specific user group.
I have a form set up and I used a database join element to give me a dropdown list showing usernames with the value of each item being the user id. I wanted to restrict this to show only users within a specific user group so I added the following to the "data-where" tab in the additional join statements box:
LEFT JOIN foo_user_usergroup_map ON (foo_users.id=foo_user_usergroup_map.user_id) WHERE foo_user_usergroup_map.group_id=12
I am getting an error telling me I have a syntax issue but I am not able to see the problem. Anyone done something similar ?
Cheers
B
I am trying to show a list of users (usernames) in a specific user group.
I have a form set up and I used a database join element to give me a dropdown list showing usernames with the value of each item being the user id. I wanted to restrict this to show only users within a specific user group so I added the following to the "data-where" tab in the additional join statements box:
LEFT JOIN foo_user_usergroup_map ON (foo_users.id=foo_user_usergroup_map.user_id) WHERE foo_user_usergroup_map.group_id=12
I am getting an error telling me I have a syntax issue but I am not able to see the problem. Anyone done something similar ?
Cheers
B