Page 1 of 1

Error in SQL syntax near 'limit 1' (v2022)

Posted: Wed May 01, 2024 9:47 am
by wincode2008

I am using version 2022. How to I manually change database connection. I already change the
connection in src/config.production.php and src/config.development.php.

But when I run the program, It is working . But when I access the custom pages, the error below appears

Fatal error: Uncaught PDOException: SQLSTATE[42000]: Syntax error or access violation: 1064 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 'limit 1' at line 1 in E:\xampp\htdocs\pts_server_balamvibe\vendor\doctrine\dbal\src\Driver\PDO\Connection.php:72 Stack trace: #0 E:\xampp\htdocs\pts_server_balamvibe\vendor\doctrine\dbal\src\Driver\PDO\Connection.php(72): PDO->query('Select equivale...') #1 E:\xampp\htdocs\pts_server_balamvibe\vendor\doctrine\dbal\src\Connection.php(1050): Doctrine\DBAL\Driver\PDO\Connection->query('Select equivale...') #2 E:\xampp\htdocs\pts_server_balamvibe\src\phpfn.php(5143): Doctrine\DBAL\Connection->executeQuery('Select equivale...') #3 E:\xampp\htdocs\pts_server_balamvibe\src\phpfn.php(5305): PHPMaker2022\Prjtabulation\ExecuteQuery('Select equivale...', NULL) #4 E:\xampp\htdocs\pts_server_balamvibe\details.php(208): PHPMaker2022\Prjtabulation\ExecuteScalar('Select equivale...') #5


Re: Error in SQL syntax near 'limit 1' (v2022)

Posted: Wed May 01, 2024 1:28 pm
by arbei

You should enable Debug to check the complete SQL.