application role sql 2008

StewSupport
StewSupport used Ask the Experts™
on
ok so i logged into sql as admin and did the following
CREATE APPLICATION ROLE test
    WITH PASSWORD = 'test'
    , DEFAULT_SCHEMA = test;
GO


exec sp_setapprole test, 'test'


now in my web.config, what should my connection string look like for my asp.net web application?
<add name="testconnectionstring" connectionString="Data Source=testdb;Initial Catalog=testcatalog;Persist Security Info=True;User ID=test;Password=test; Connect Timeout=360" providerName="System.Data.SqlClient" />
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
data source should be DBServerName\InstanceName
InitialCatalog should be databasename
<add name="testconnectionstring" connectionString="Data Source=Database\Instance; Initial Catalog=testdb;Persist Security Info=True;User ID=test;Password=test; Connect Timeout=360" providerName="System.Data.SqlClient" />

Open in new window

Author

Commented:
yes i got that but it doesn't see the login info because i'm using the login info as application role info. what login info should i use
you have to create a user with username test and password test.
Role has nothing to do in connection string, its purely as SQL Identity....

Author

Commented:
so then how do i assign this user to that application role

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial