Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


New login is created but user cant login using credientials ?


New login is created but user cant login using credientials ?

Author
Message
maida_rh
maida_rh
SSC Rookie
SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)

Group: General Forum Members
Points: 46 Visits: 111
I created users with login option in security tab in sql server 2008 R2 running on windows 7 successfully and grant permissions to :


Use dummydb
Grant REFERENCES ON OBJECT::vuUser TO nvp
GO




Use dummydb
Deny INSERT,SELECT,UPDATE,DELETE ON OBJECT::dummyDB.userTb to nvp
GO


nvp user can login successfuly and resctriction work great but when i create user and grant permissions as above on sql serevr 2008 R2 running on windows server 2008.User login successfully but when i try to grant permission using above code,it says:

Msg 15151, Level 16, State 1, Line 2
Cannot find the object 'usertb', because it does not exist or you do not have permission.
.
Is their is something I am doing wrong or I need to try something else ?????
database+table name is correct...

Need urgent help n thanks in advance
boeta.schutte
boeta.schutte
Valued Member
Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)

Group: General Forum Members
Points: 53 Visits: 325
Don't forget Schema name. Dataabse.Schema.Table

Deny INSERT,SELECT,UPDATE,DELETE ON OBJECT::dummyDB.dbo.userTb to nvp
maida_rh
maida_rh
SSC Rookie
SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)

Group: General Forum Members
Points: 46 Visits: 111
Ok.I tried :

Use dummydb
Deny INSERT,SELECT,UPDATE,DELETE ON OBJECT::userTb to nvp
GO



and work f9 and have another issue,How can i restrict user who login through windows authentication ?

and run this query :

SELECT * FROM sys.tables;
SELECT * FROM sys.databases;


and it returns lists of all tables and databases which i really dont want
boeta.schutte
boeta.schutte
Valued Member
Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)Valued Member (53 reputation)

Group: General Forum Members
Points: 53 Visits: 325
Why do you want to block Windows Authentication ? I don't think that is a great idea.

You can create a logon trigger as follow:

IF EXISTS (SELECT isntuser FROM syslogins where isntuser = 1 and name = system_user)
PRINT 'Windows Authentication';
ELSE
PRINT 'SQL Authentication';
GO
maida_rh
maida_rh
SSC Rookie
SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)SSC Rookie (46 reputation)

Group: General Forum Members
Points: 46 Visits: 111
User can only perform select query on a view of a specified database and he is not allow to access any other stuff i.e. tables,databases,views and stored procedures
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search