On Tue, Mar 11, 2008 at 12:18 AM, Julian Wood <[EMAIL PROTECTED]> wrote:
> In the provided example for tapestry-acegi, I have a question about
>  the GrantedAuthorityBean table. That is, if I add more users which
>  share roles, each role will create a new row in the GAB table. How can
>  this be avoided?

Users and Roles are a many-to-many relation ship. You'll need a third
table to normalize the sql. However, as the example app is just an
example, a better approach would be to create a table for the roles.

Users table:
user_id
username
password

Roles table:
role_id
name

Users_Roles tables
user_id
role_id

-- 
 regards,
 Robin

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to