DIXF - "set based option is only supported for direct field assignments"


I am trying to import the data using the “Site specific order settings” group name. And after the import the data can be seen on the “Product information management/Release products” and on the “Plan” tab “Site specific order settings” button opens the form shows the data that was imported for the selected item in the Released products list page.

As of now when I import the data it only inserts that where there is no data for the given item. But when there is data already in the screen then it is updating the existing fields (like site and other information)

The staging data looks good and it only updating the data in the target when I did the “Copy data to target” button on the execution history screen.

So, I debugged the DMFEntityWriter/Write() method but here in this method it is selecting the record to update (selectForUpdate(true)) and it is always updating the records. There are 3 classes are used in the process and these classes extend the DMFEntityBase class.




to process the data before it updates the data in the target.

I am not sure if I am heading in the right direction here, but I looked at the DMFEntitBase class’s copyStagingToTarget() and overridden the method in all the above classes and after that , I navigated to the Data import export Framework/Area page under the Setup clicked on the “Target entities” menu item to open the form. I searched for the “Site specific order settings” under the Entity column and clicked on the “set-based processing” to directly insert the data from the staging to the target. But I am getting the below warning and not sure if this is the right approach and how to resolve the warning to move forward?

Can somebody please provide some inputs how to proceed in my scenario?

Version : AX 2012 R3 CU13



What problem are you trying to solve?

You seem to have a problem with the standard logic that updates existing items, instead of tryuing to insert duplicate values (which would fail), but it sounds correct to me.

By the way, selectForUpdate(true) has nothing to do with whether the record will be inserted or updated. It indicates that an update lock should be obtained when fetching a record from dataabase.

Martin, I am trying to figure out why it updates the existing records instead of adding? When there are no records the existing code inserts as expected and our users want to be able to insert whole bunch of items. But instead it is wiping out the existing records and inserting (updating) the new ones and the previous are gone.