You have an error in your SQL syntax; check the manual that correspond InMotionFans 7 years ago Answered You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'FROM `
Sorry to hear you are getting a Syntax error in your SQL Query. I see you are using MariaDB in a MySQL function. While it 'should' be compatible, I cannot make any guarantees. The function code you gave was not helpful, so it was eliminated from your question. The error message is about a simple syntax error in the query. You will need to evaluate the query carefully and find the syntax error. You may also want to refer to our article on the 1064 Syntax error for MySQL. It should be close enough to help you out.