🔌 API

DATABASE_QUERY_ERROR

👤 nafisa
Q
Question
Hi,
I am trying to import sales order referring http://blog.crm-now.de/2018/02/26/new-api-description-and-new-example-code-for-crm-rest-operations/?lang=en.
I did have to add "productid" to the "SalesOrder" element, as it is marked as a mandatory field despite the fact it is also referenced in the "LineItems" array.
But i am getting this error
{"success":false,"error":{"code":"DATABASE_QUERY_E
A
Community Solution
✓ Answered
Edit the MySQL my.cnf file

bash
sudo nano /etc/mysql/my.cnf


Add the following to the end of the file:

bash
[mysqld]
sql_mode = NO_AUTO_VALUE_ON_ZERO


Restart the MySQL service

bash
sudo service mysql restart
← Back to API Join to answer →