Home All Groups Group Topic Archive Search About

Having problem with SQLConnection.ChangeDatabase() method.

Author
30 Mar 2005 10:43 PM
Ken Varn
I have multiple databases in which I want to traverse.  Each database is
secured using Applicaiton Roles.  I use the SQLConnection object to connect
to the first database.  I run the sp_setapprole procedure and I can access
the tables with no problem.  However, when I try to call the ChangeDatabase
method on my connection object, I get an exception thrown stating that my
application role user is not a valid user in the database.  If I connect to
the same database using Open, it works fine.  I don't quite understand what
is going on here.  Can anyone help?

--
-----------------------------------
Ken Varn
Senior Software Engineer
Diebold Inc.

EmailID = varnk
Domain = Diebold.com
-----------------------------------

AddThis Social Bookmark Button