none
Not sure why this happened...looking for assistance. RRS feed

  • Question

  • I had the following error on a LINQ to SQL mapped object when I tried to Insert it into the database

       at System.Data.Linq.ChangeDirector.StandardChangeDirector.Insert(TrackedObject item)
       at System.Data.Linq.ChangeProcessor.SubmitChanges(ConflictMode failureMode)
       at System.Data.Linq.DataContext.SubmitChanges(ConflictMode failureMode)
       at System.Data.Linq.DataContext.SubmitChanges()
       at InventoryData.CustomerForm.toolStripButton1_Click(Object sender, EventArgs e) in

     

    Also, this particular class was mapped to used a stored procedure for both the updates and inserts.  I am currently at a stop till I figure this little dilemma out.

     

    Monday, January 26, 2009 4:37 PM

Answers

  • I actually found the problem a little while after I posted this.  For some reason I had two columns with the Identity option selected, so one wasn't being auto filled in.  Once I fixed that everything is fine...well in as well as can be expected.

     

    Mark

    Monday, January 26, 2009 8:29 PM

All replies

  • Are you tracking changes? Meaning, do you have object tracking enabled? Or is this on a new record you are inserting?


    Scott
    Monday, January 26, 2009 8:26 PM
  • I actually found the problem a little while after I posted this.  For some reason I had two columns with the Identity option selected, so one wasn't being auto filled in.  Once I fixed that everything is fine...well in as well as can be expected.

     

    Mark

    Monday, January 26, 2009 8:29 PM