In my application my user model has a foreign key to the address table. My problem is after I insert the the address into the address table I have to run a LINQ query on the whole population of the address table looking for the record I just persisted. Is there a better way to get the primary key from a record that was just persisted?
问问题
191 次