Swagger + Database problem
I have database in this text file and I'm trying to delete it but I have problem in this picture:
Microsoft.Data.SqlClient.SqlException (0x80131904): The DELETE statement conflicted with the REFERENCE constraint "FK_Orders_Employees". The conflict occurred in database "Northwind", table "dbo.Orders", column 'EmployeeID'.
If you have any ideal please let me know. Thank you so much!
1 Reply
that means you have orders that reference that employee, so it's preventing you from deleting it
you would need to delete the orders first