PkeyToValue method doesn't consider that the field name could be different from the field db property.
In "non-flat version" (during insert with compound keys) it looks for property named as pkey[i] (db property) but it's doesn't find anything because the client uses field name.
PkeyToValue method doesn't consider that the field name could be different from the field db property. In "non-flat version" (during insert with compound keys) it looks for property named as pkey[i] (db property) but it's doesn't find anything because the client uses field name.