M
Mark Olbert
I'm getting a "null object" exception when I try to update a dataset where a new master and a new
child record have been created. In other words, Master has a new record and Child has a new record
whose foreign key is the Master record's autosequence idnumber.
If I create just a new Master record, call SqlAdapter.Update(), and then create a new Child record
for the Master record and call SqlAdapter.Update() no exception is thrown.
Both Master and Child have their autonumber idfields set to seeds of -1 and increments of -1 (i.e.,
so newly-created records are assigned unique IDs that "grow" down). I did this because I was running
into some other problems when creating new master/child tuples.
The Update, Delete and Accept/Reject rules for the Master/Child relation are set to Cascade.
Does ADO.NET not support the simultaneous creation of new Master/Child tuples? Or must I
programmatically control the sequence of when the Master and Child adapters call Update()?
Thanx in advance for any help or advice.
- Mark
child record have been created. In other words, Master has a new record and Child has a new record
whose foreign key is the Master record's autosequence idnumber.
If I create just a new Master record, call SqlAdapter.Update(), and then create a new Child record
for the Master record and call SqlAdapter.Update() no exception is thrown.
Both Master and Child have their autonumber idfields set to seeds of -1 and increments of -1 (i.e.,
so newly-created records are assigned unique IDs that "grow" down). I did this because I was running
into some other problems when creating new master/child tuples.
The Update, Delete and Accept/Reject rules for the Master/Child relation are set to Cascade.
Does ADO.NET not support the simultaneous creation of new Master/Child tuples? Or must I
programmatically control the sequence of when the Master and Child adapters call Update()?
Thanx in advance for any help or advice.
- Mark