limit form plugin error

mahmoodee

Member
Hello,
I want to limit add records to form 'students' for each user groups ,so I create a limit list called 'limit group ' with followings elements :
*id
*groupid
*max
I add some records to this table
groupid=10 , max=5
groupid=8 , max=10
groupid=7 , max=15

then I edit form and add the limit plugin with the following setting.

* Connection: the connection you store the 'limit group' list in
* Lookup list: 'limit group'
* Type: 'Group'
* Lookup element: 'groupid'
*Max element: 'max'

Now I try to add record to 'student' form and get this error
1064
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 'Limit WHERE `Limit`.`Groupid` IN (1,6,7,8)' At Line 2 SQL=SELECT MAX(`Limit`.`Max`) FROM Limit WHERE `Limit`.`Groupid` IN (1,6,7,8)

How I can solve this problem
thank you
 
sorry, I forget to set User element.
I set -user element- in limit plugin config and error not show.
but the plugin not work , I can add more 5 limit. why ?
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top