Hi I have a parent->child form.
Here's the data:
Parent
======
id Name
--- ----
P1 Rick
P2 Chris
Child
=====
ParentId CategoryCode Sequence
-------- ------------ --------
P1 C1 1
P1 C1 2
P1 C2 3
P2 C3 4
The child table doesnt have a primary key. In addition, as you can see, the child table has duplicate category codes within the same parent id.
In the child bizobj, I set PrimaryKey to "" (since there's no PK). The child data is not going to be modified. I register the child bizobj as a child of the parent. When I navigate to parent P1, I get the following error "Failed to enable constraints. One or more rows contain values violating non-null, unique, or foreign-key constraints."
The data is sql server, there is a non-unique index on the ParentId field.
I have tried setting
this.PrimaryKeys = new string[] {"ParentId", "CategoryCode","Sequence"};
figuring this might work but I get the same error -
Any ideas?
TIA,