Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Questions about db_owner role. Expand / Collapse
Author
Message
Posted Tuesday, July 28, 2009 9:25 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Friday, August 31, 2012 3:42 PM
Points: 19, Visits: 262
Hi,

I am using SQL Server 2005 (SP3).

I created a new login via SSMS. I went to Security-->Logins-->New Login. I created a new login called newUser with a password.

Then I went to my User Database called MyDB. I went to Security-->Users-->New User. Under Login name and User Name I typed in newUser. Under the Database Role Membership I check db_owner.

Then I gave this UserID and Password to my co-worker at work. When my co-worker uses SSMS and users newUser as the UserId and the correct password, in SSMS he is unable to see MyDB. He is also unable to create new Stored Procs etc. Why is that? Once he is the db_owner he should be able to do everything on this database (including DROP). I don't want to make newUser as the Owner.

Any ideas? tips?
Post #760859
Posted Tuesday, July 28, 2009 9:36 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: 2 days ago @ 11:25 AM
Points: 1,426, Visits: 3,224
Perhaps your co-worker is not logging in with that user id and password. He might be connecting with integrated security.

Why don't you log in yourself with that user and password and see what you get?




The probability of survival is inversely proportional to the angle of arrival.
Post #760876
Posted Tuesday, July 28, 2009 1:14 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Friday, August 31, 2012 3:42 PM
Points: 19, Visits: 262
I get the same result as my co-worker.
Post #761046
Posted Tuesday, July 28, 2009 1:18 PM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 4:07 PM
Points: 5,976, Visits: 12,888
run 'exec sp_helpuser ' in the database, what does that return?

---------------------------------------------------------------------

Post #761048
Posted Thursday, July 30, 2009 8:50 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Friday, August 31, 2012 3:42 PM
Points: 19, Visits: 262
I ran exec sp_helpuser 'newUser'

I got back UserName as newUser
GroupName as db_owner
LoginName as newUser
DefDBName as MyDB
DefSchemaName as dbo
UserId
SID

Please help.
Post #762464
Posted Friday, July 31, 2009 8:36 AM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Monday, July 28, 2014 7:30 AM
Points: 1,081, Visits: 1,483
Mayne the user didn't get matched up with the login.
Go to Security - Login and look at the porperties for the login and see if the user database is checked for dbo.


Tim White
Post #763144
Posted Friday, July 31, 2009 9:02 AM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Thursday, July 17, 2014 10:56 AM
Points: 3,924, Visits: 1,607
2 Tim 3:16 (7/31/2009)
Mayne the user didn't get matched up with the login.
Go to Security - Login and look at the porperties for the login and see if the user database is checked for dbo.


execute sp_change_users_login 'loginname','username'


SQL DBA.
Post #763171
Posted Saturday, August 1, 2009 4:20 PM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 4:07 PM
Points: 5,976, Visits: 12,888
KP (7/30/2009)
I ran exec sp_helpuser 'newUser'

I got back UserName as newUser
GroupName as db_owner
LoginName as newUser
DefDBName as MyDB
DefSchemaName as dbo
UserId
SID

Please help.

This looks correct.

You say this id cannot create stored procs etc but if it cannot even see the database how are you getting that far to test? Are you able to issue the use mydb command in a query window and switch to the database?

I suggest you run profiler as the id logs on and track what happens. Include errors and warnings in the trace. If its a permissions problem on some system object that will be the last command issued and the trace will stop there.

Post any erors you haave received if any because what you report so far does not add up.


---------------------------------------------------------------------

Post #763679
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse