Solved

Error: Field cannot be empty

  • 4 October 2022
  • 3 replies
  • 586 views

I’m trying to create a new Customer using the PUT Method in Postman, and I’m receiving the following error message.

"error": "Inserting  'Location' record raised at least one error. Please review the errors.",

"SalesAccount": {

     "error": "'Sales Account' cannot be empty."

},

Here’s what I’m sending through the Body.

{
"CustomerName": {"value":"TEST TEST"},
"Location":[
{"SalesAccount": {"value": "60040"}}
]
}

I copied this Sales Account value from another record, so I’m not sure why it’s not recognizing the value.

icon

Best answer by DConcannon 4 October 2022, 22:43

View original

3 replies

Userlevel 6
Badge +2

Hi @brettb,

Is it possible for you to send a customer class? This can default all the customer accounts/sub-accounts for you. If you are using sub-accounts, the sales sub-account is also required, as well as other combinations, depending on your configuration.

@DConcannon I was able to submit a customer class and that allowed me to create a new customer. Thanks for the help! 

Userlevel 7
Badge +4

Hi @brettb,

As recommended by @DConcannon, you need to provide the CustomerClass as well. So you can try the below payload structure to see if that helps,

{

    "CustomerID": {

        "value": "Cust02"

    },

    "CustomerName": {

        "value": "Customer 01"

    },

    "CustomerClass": {

        "value": "LOCAL"

    },

    "MainContact": {

        "Email": {

            "value": "Cust01@gmail.com"

        }

    }

}

 

Additionally, you can refer the following documentation, https://help.acumatica.com/(W(2))/Help?ScreenId=ShowWiki&pageid=51059f24-01f8-4d78-a17b-cc255fe8b8e0

 

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved