I have added two roles to sql server. One called Officeusers. The other AdminUsers
Added the appropriate logins to these roles. For example; james, john, ahmad to OfficeUsers and Mat, Nick to AdminUsers.
How can these roles be now used in a connectionstring? I can use each user login and his relevant password in a connectionstring to connect to sql server but not sure how/where/when the Roles come in to development.
i.e. do I need to use the role in the connectionstring? if so then what happens to the password.
Not quite clear about all these.
Roles are not used in connection strings. They are just ways to group different logins together for assignment of security priveleges.
You assign all your priveleges to the role instead of assigning every privelege to every user individually.
If it's not practically useful, then it's practically useless.