private void CreateBook() { var book = new Book(); var addBook = new BookBusinessLayer(); book.Author = txtAuthor.Text; book.Price = decimal.Parse(txtPrice.Text); book.Title = txtTitle.Text; book.Year = txtYear.Text; book.publisherId = int.Parse(dlistPublisher.SelectedValue);//this is Foreign Key addBook.AddBook(book); }
SET IDENTITY_INSERT Book ON
SET IDENTITY_INSERT Table_Name ON INSERT INTO Table_Name (ID, name) VALUES (5, 'David') SET IDENTITY_INSERT Table_Name OFF
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)