Mandatory object fields & CSV import

Hi,

I’m using the CSV Adapter to import some data in object A.

Object A is related to object B (the id of object B is a mandatory functionnal key of object A) which itself is related to objects C & D (the ids of C & D are the mandatory functional keys of object B). The CSV used contains the functional keys of object C & D (it actually uses other fields to fill the functional keys of object D).

I would expect the adapter to fail if any of the functionnal keys of C & D are absent, but the observed behavior is that if any of the keys is present, the adapter seems to take the first found object B that corresponds to the criteria.

Is there any way of achieving this without having to write a custom adapter?

PS: Updated with model.

It might be worth mentioning that C & D objects both have two functionnal keys.

I also noticed another unexpected behavior: the imported functionnal keys can carry any random value, if they do not exist, the XML Import will fill in with the first found object B.

In the following example, the values of the keys for object C do not exist, but the import is successful and assigns the existing values (key1 and key2)

<?xml version="1.0" encoding="UTF-8"?>
<simplicite xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.simplicite.fr/base" xsi:schemaLocation="http://www.simplicite.fr/base http://www.simplicite.fr/schemas/base.xsd">
<object>
	<name>A</name>
	<action>upsert</action>
	<data>
		<rprCId.rprCkey1>jhgfjhv</rprCId.rprCkey1>
		<rprCId.rprCkey2>hvjhv</rprCId.rprCkey2>
		<rprDId.rprDkey3>key3</rprDId.rprDkey3>
		<rprDId.rprDkey4>key4</rprDId.rprDkey4>
	</data>
</object>
</simplicite>