> hello am a beginner to this dbunit framework.
> i need to insert some tuples from my xmlfile on to database using the
> but i wann to genetate this primarykey from dbunitframework itself. so that
> i can avoid specifying de same on that xml file.
> how can i use dbunit in this manner??
> suggest me plz
I've found that dbunit doesn't work very well unless you allow it to
insert the primary keys of the test data. Otherwise it cannot find the
If you're using Microsoft SQLserver, I don't know anyway to override the
automatic primary keys. You can, however, turn that off and run dbunit
once to insert your test data. Then, after turning the primary key
generation back on, dbunit will still be able to update the records it
inserted. This works until you add a new record to your dbunit test
data, and then you need to repeat the procedure.