Setting Cost Estimate Type on Sales Order Lines in Netsuite

Hi,

Question about Netsuite/Sales Orders:
Is anyone setting fieldid: costestimatetypesuccessfully on item lines?

Example of what I am trying to do:

In this case Line ID is used as a key to find the existing line.

Error I get: invalid_key_or_ref

I have tried multiple combinations leading to the same error, namely:

  1. Mapping the field Items : Cost Estimate Type (Name) using:
  • "Item Defined Cost" (shown in pic), "ITEMDEFINED" (this id shows on the backend using netsuite field explorer), "4" (netsuite also stores a costestimatetypearray on the sales order record that has numeric keys)
  1. Mapping the field Items : Cost Estimate Type (Internal ID).
  • the same 3 options used to no avail;

All of these tests failed with the same error. Netsuite's own documentation points to using:
nlapiSetFieldValue('costestimatetype', 'PREFVENDORRATE'); with scripts.

Looking at the logs in celigo during my efforts:
r.setSublistText({"sublistId":"item","fieldId":"costestimatetype","line":0,"text":"Item Defined Cost"});

Seems like the io restlet's trying to perform the wrong method? Any ideas how to fix this? If this is a bug - any workarounds possible?

Thanks,

Marin

Hi Marin,

I'm fairly certain this is a bug in the Celigo connector for NetSuite list fields with an internalid that isn't numerical but use a string as the key.

Unfortunately the only workaround I know of is to change the API version on your import to Suitescript 1.0 and then to do the mapping on Items : Cost Estimate Type (Name) (internalid doesn't work in both 2.0 and 1.0)

This worked. Many thanks, Bas!