Hello,
I have been adding fields to the INUnits table to better fit our needs, and so far it seems to be exactly what we need. I followed the example from this link: https://www.acumatica.com/blog/creating-acumatica-dac-extension-tables/. However I have ran into issue relating to copy and pasting.
When I try and copy this SKU to make a new one this happens
![](https://uploads-us-west-2.insided.com/acumatica-en/attachment/125580d3-61f3-4341-a8ec-24f0fa9a559d.png)
![](https://uploads-us-west-2.insided.com/acumatica-en/attachment/bb0495b8-8b9e-4bb3-8546-7aea701022e9.png)
![](https://uploads-us-west-2.insided.com/acumatica-en/attachment/1f00b76e-5e59-4587-86c4-4ff8a7a80ea0.png)
It makes sense that the key cannot be NULL, but why is it trying to insert the extension table row before the main row exists?
Regardless, its not the end of the world to me if I am unable to bring over all of the UOMs, so I added this code to the graph extension based on this example: https://stackoverflow.com/questions/56261490/hiding-custom-fields-in-copy-past-option
PXViewName(Messages.InventoryUnitConversions)]
PXImport(typeof(INUnit))]
PXCopyPasteHiddenView]
public PXSelect<INUnit, Where<INUnit.inventoryID, Equal<Current<InventoryItem.inventoryID>>>> itemunits;
And am met with this when I copy and paste:
![](https://uploads-us-west-2.insided.com/acumatica-en/attachment/83300c0a-b4bf-401d-bff6-8b3fcfb47f9e.png)
This is able to be saved. However, I know from trying to add a base unit to base unit conversion by hand that this should not work, I am also confused as to why it is showing up in the first place, as I would expect it to be blocked by the filter, or at least show up in both scenarios as the EACH to EACH base unit conversion is not present when I do not have the filter.
So, I have 2 paths/questiosns.
1: How can I keep the Units of Measure and ensure that it is saved in the proper order so the recordID is not null
or
2: How can I make sure that the “From Unit” “EACH” does not get created out of thin air on copy paste.
Thanks in advance