locked
DataSet.Merge RRS feed

  • Question

  • I know this has probably been posted and answered but I do not have the time to read through all the search results as I need to fix this by tomorrow.

    I have two DataSets (EntityDataSet and tempDataSet). EntityDataSet is the main dataSet and is used to maintain the database as well as plugin to the front end when the user adds new records. Due to some fantastic errors we now have to create tempDataSet and then merge EntityDataSet with it, and then send tempDataSet to the backend and save the new/edited data. When it comes back we then clear EntityDataSet and merge tempDataSet with it.

    The problem I am now having is that when I call the save method, and the tempDataSet.Merge(EntityDataSet); code is hit, the merge happens except that one value is left out of a table. It is the same column every time and it only happens on one screen, this code is part of a generic base class. This value is selected by the enduser and is a foreign key, so it is needed and we can not hard code, which would be bad practice anyway.
    Monday, April 2, 2007 2:42 PM