Hi @pdsqsql
Thanks for the Question and using Microsoft Q&A
As per my understanding, your facing issues in DML operations in Azure SQL managed instance.
Granting DML (Data Manipulation Language) permissions in Azure SQL Managed Instance involves providing users or roles with the necessary permissions to perform operations like INSERT, UPDATE, DELETE, and SELECT on database tables. Here’s a step-by-step guide to help you through the process:
Step-by-Step Guide
- Connect to Azure SQL Managed Instance: Use SQL Server Management Studio (SSMS) or any other SQL client to connect to your Azure SQL Managed Instance.
- Select the Database: Ensure you are connected to the correct database where you want to grant permissions.
- Grant Permissions: Use the GRANT statement to provide the necessary DML permissions. Here are some examples: Grant SELECT Permission:
GRANT SELECT ON [schema_name].[table_name] TO [user_or_role];
Grant INSERT Permission:GRANT INSERT ON [schema_name].[table_name] TO [user_or_role];
Grant UPDATE Permission:GRANT UPDATE ON [schema_name].[table_name] TO [user_or_role];
Grant DELETE Permission:GRANT DELETE ON [schema_name].[table_name] TO [user_or_role];
Example
Suppose you have a table named Employees in the HR schema, and you want to grant SELECT and INSERT permissions to a user named xyz. You would execute the following commands:
GRANT SELECT ON HR.Employees TO
xyz;
GRANT INSERT ON HR.Employees TO
xyz
Hope this helps. Do let us know if you have any further queries