Articles in this section

Note attribute fields in Shopify

Issue:

We are attempting to solve the Note Attribute Fields. Because these fields are not required in Shopify, the Note Attribute number may differ for each order. We are trying to solve that with the following (see the example for poFile:

{{#contains $.[note_attributes[0\]].name "poFile"}} $.[note_attributes[0\]].value
{{else}}{{#contains $.[note_attributes[1\]].name "poFile"}} $.[note_attributes[1\]].value
{{else}}{{#contains $.[note_attributes[2\]].name "poFile"}} $.[note_attributes[2\]].value
{{else}}{{#contains $.[note_attributes[3\]].name "poFile"}} $.[note_attributes[3\]].value
{{else}}{{#contains $.[note_attributes[4\]].name "poFile"}} $.[note_attributes[4\]].value
{{else}}{{#contains $.[note_attributes[5\]].name "poFile"}} $.[note_attributes[5\]].value
{{else}}{{#contains $.[note_attributes[6\]].name "poFile"}} $.[note_attributes[6\]].value
{{else}}{{#contains $.[note_attributes[7\]].name "poFile"}} $.[note_attributes[7\]].value
{{else}}{{#contains $.[note_attributes[8\]].name "poFile"}} $.[note_attributes[8\]].value
{{else}}{{#contains $.[note_attributes[9\]].name "poFile"}} $.[note_attributes[9\]].value
{{else}}{{#contains $.[note_attributes[10\]].name "poFile"}} $.[note_attributes[10\]].value
{{else}}{{#contains $.[note_attributes[11\]].name "poFile"}} $.[note_attributes[11\]].value

{{else}} undefined {{/contains}} {{/contains}}{{/contains}} {{/contains}} {{/contains}} {{/contains}} {{/contains}} {{/contains}} {{/contains}} {{/contains}} {{/contains}} {{/contains}} "

The error we are getting speaks to a NetSuite field explained below.

Source Code Message
netsuite exceeded_max_field_length

"Unable to create the order in NetSuite for the Shopify order #********* Failed to create, update/transform record because The field custbody_celigo_etail_transaction_ids contained more than the maximum number (300) of characters allowed."

Resolution:

This is the formula that should be used:

{{#each $.note_attributes}}{{#compare this.name "===" "poFile"}}{{this.value}}{{/compare}}{{/each}}

Here is another alternative solution to resolve the error "Failed to create, update/transform record because The field custbody_celigo_etail_transaction_ids contained more than the maximum number ( 300 ) of characters allowed." You can accept until 300 characters and cut off the rest. This resolution would not affect anything in your order.

To resolve this error, create a handlebar expression in the order flow mapping:

  1. In the Shopify - Netsuite integration app, go to the Flows > Order >Shopify order to NetSuite sales order (add) flow.
    mceclip0.png
  2. Click the mapping icon as shown as a sample in the screenshot.
  3. Set the handlebar expression below on the export field (Shopify) of the Etail Transaction Id(s). See the sample screenshot below.
    {{substring sourceTransactionIds "0" "300"}}

    mceclip1.png
  4. Click Save and Close.
  5. Go to the integration.io Dashboard and retry the error message to resolve the issue.

Was this article helpful?
1 out of 1 found this helpful

Comments

0 comments

Please sign in to leave a comment.