Incorrect syntax near fejl
HejJeg får følgende fejl når jeg køre en side hvor den skal slette lidt data i en MsSql tabel.
Hvad kan fejlen være?
Line 1: Incorrect syntax near '*'.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Data.SqlClient.SqlException: Line 1: Incorrect syntax near '*'.
Source Error:
Line 81: OurCommand = new SqlCommand("DELETE * FROM ssKategori WHERE KatNr = " + SelectedID, OurConnection);
Line 82: OurConnection.Open();
Line 83: OurCommand.ExecuteNonQuery();
Line 84: OurConnection.Close();
Line 85: LoadData();
Source File: D:\Users\Home\LocalUser\wwwroot\SweetSpice\admin\kategori_manage.aspx Line: 83