dotnet / dotnet/EntityFramework.Docs
IDENTITY_INSERT requires ALTER permissions
- Dominant language
- Mermaid
- Stars
- 1.7k
- Forks
- 2k
- Avg merge
- 7d 23h
- Merged PRs (30d)
- 16
Description
While running down an error, I discovered that a user must own the table or have ALTER permission on the table to execute SET IDENTITY_INSERT. I think this is worth noting in the document.
Error:
`Cannot find the object "dbo.Table" because it does not exist or you do not have permissions.`
---
#### Document Details
⚠ *Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.*
* ID: e621a525-7104-74bf-5a17-9f5761f75fab
* Version Independent ID: 3d0e675b-3b2a-ebd9-273b-312c5c6ac092
* Content: [Setting Explicit Values for Generated Properties - EF Core](https://docs.microsoft.com/en-us/ef/core/saving/explicit-values-generated-properties)
* Content Source: [entity-framework/core/saving/explicit-values-generated-properties.md](https://github.com/aspnet/EntityFramework.Docs/blob/master/entity-framework/core/saving/explicit-values-generated-properties.md)
* Product: **entity-framework**
* GitHub Login: @rowanmiller
* Microsoft Alias: **divega**
Contributor guide
Assessment
This issue has not been assessed yet.