in that it has feilds: ModelNoId, ModelNo, Narration.
The values are inserted and shown in a data grid view.
While inserting values in tbl_ModelNo
if the same ModelNo inserted as that in the grid view it should not be inserted and it must show a message that THIS MODEL No already exist.How to write code for this in c#
nilesh PatilPosted Mar 30, 2013, 5:45 AM
if exists(select * from tbl_ModelNo where ModelNo=@ModelNo)
Begin
Set @outputParamer='Model Number Already Exists'
return
End
-- Here write your Insert Query