From: Matthew B. <mat...@ou...> - 2006-03-08 15:24:11
|
Paul Trafford wrote: > At 15:09 08/03/2006, Antony Corfield wrote: > >> Can someone, Jon perhaps, remind me what special_groups_a etc. are >> used for in users table? > > You can deduce memberships of the system generated groups. The total > value is made up of components totted up from: > > 2 allusers > 4 allstaff > 8 allstudents > 16 allothers > 32 campus.users > 64 campus.staff > 128 campus.students > 256 campus.other > > e.g. > special_group a=102 => campus.staff, allstaff, allusers, campus.users > special_group a=170 => campus.students, allstudents, allusers, campus.users I think User.addToGroup() and User.removeFromGroup do the dirty work. They are used so that you can have very large groups without having a large number of entries in the members table. One problem with them on PostgreSQL is that you can't have an index on them that improves performance when doing bitwise operations which means that the DB always has todo a full table scan doing the bitwise operation for each row. -- -- Matthew Buckett, VLE Developer -- Learning Technologies Group, Oxford University Computing Services -- Tel: +44 (0)1865 283660 http://www.oucs.ox.ac.uk/ltg/ |