Is there a way to duplicate a db entry from linq to sql in C #?
Id [int] IDENTITY(1,1) NOT NULL PRIMARY KEY,
[Foo] [nvarchar](255) NOT NULL,
[Bar] [numeric](28,12) NOT NULL,
...
Given the table above, I would like to duplicate the record (but give it a different identifier), so that new fields added to the database and the Linq dbml file later will be duplicated to change this code, which duplicates the record.
those. I do not want to write newRecord.Foo = currentRecord.Foo;for all fields in the table.
source
share