SQL Action Query not running

12 years 4 months ago #180947 by Websatisfaction
SQL Action Query not running was created by Websatisfaction
Hey,

I need to be able to add users to several usergroups when they subscribe to a specific Subscription. In order to do this, I added the following query to the SQL Actions tab:

INSERT INTO `#__user_usergroup_map` ( `user_id`, `group_id` ) VALUES ( [user_id], 14 ), ( [user_id], group_id ), ( [user_id], group_id ), ( [user_id], group_id ), ( [user_id], group_id ), ( [user_id], group_id );

When I use the joomla debug mode, the query appears in the list of queries executed (I tried it both with the ; and without it). The thing is that the user is never added to the groups but if i copy the query from the debug message and run it directly in the database, the query runs fine.

Any help is appreciated.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.178 seconds