July 13, 2011 at 5:30 am
Hi,
Please give me suggestion, how to resolve this issue?
--create Login script
--use master
CREATE LOGIN test1
WITH PASSWORD = 'SMTStest_1';
--use database name
--create user script
CREATE USER test1 FOR LOGIN test1
WITH DEFAULT_SCHEMA = dbo;
GO
--alter script to change which is assgin database this user.
ALTER LOGIN [test1] WITH DEFAULT_DATABASE=[test]
--Grant permission
GRANT CREATE TABLE TO [test1];
create table test3 (id_clo int)
Msg 2760, Level 16, State 1, Line 1
The specified schema name "dbo" either does not exist or you do not have permission to use it.
July 13, 2011 at 5:39 am
Have you run down the obvious, like do you have the appropreate rights? Or You need to run under correct database and correct schema.
July 13, 2011 at 5:45 am
Yes, I have correct schema (dbo) and user name.
1. Login - test1 with pw ( default db is test)
2. query editor - USE database name
3. create table - but till facing same error.
rgds
ananda
July 13, 2011 at 5:48 am
But do you have the permissions to use it?
July 13, 2011 at 5:51 am
It seems like you are not authorized to create login using deault schema. check the permissions you have on the server.
Abhijit - http://abhijitmore.wordpress.com
July 13, 2011 at 5:52 am
yes, I have full permission to use this server.
I login with sa user.. after that create one database name is test,
then create login, user etc.. and give command
grant create table to test1 ( user).
thanks
ananda
July 13, 2011 at 5:59 am
I suggest that you check both logins sys.database_permissions: http://msdn.microsoft.com/en-us/library/ms188367.aspx
July 13, 2011 at 6:41 am
Hi,
As per you suggest this URL, I am not getting clearly,
so can you explain default schema(dbo) not able to give grant permission to particular user for create table, view, function, procedure, execute, insert, update, alter table column to developer
these permission how to assign to developer(SQL user) with default schema (DBO).
Thanks
ananda
July 13, 2011 at 7:01 am
Please refer the link on CREATE TABLE :- http://msdn.microsoft.com/en-us/library/ms174979.aspx
--------------------------------------------------------------------
Copying the permissions section from the link for easy reference
Permissions:-
Requires CREATE TABLE permission in the database and ALTER permission on the schema in which the table is being created.
----------------------------------
Means you should grant the following too
GRANT ALTER ON SCHEMA::dbo TO test1.
August 8, 2014 at 2:13 pm
you need to have dbowner privileges to create table. Thanks
Viewing 10 posts - 1 through 9 (of 9 total)
You must be logged in to reply to this topic. Login to reply