简体   繁体   中英

Grant Permission to CREATE tables - SQL Server

What is the SQL command for giving a user permissions to create (and delete) tables? I am looking for something similar to this:

GRANT INSERT, UPDATE, SELECT ON Customers TO Joe

I have spent some time Googling for the answer.

When I googled, I got right to TechNet . It looks like you want:

GRANT CREATE TABLE

As in:

USE AdventureWorks2012;
GRANT CREATE TABLE TO MelanieK;
GO

Two Options

  1. GRANT CREATE TABLE TO Joe AS dbo
  2. Add the user to the fixed database role: db_ddladmin

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM