CodeIgniter Forums
Model Insert Error / DatabaseException #1064 - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5)
+--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24)
+--- Thread: Model Insert Error / DatabaseException #1064 (/showthread.php?tid=89105)



Model Insert Error / DatabaseException #1064 - lelolenda - 01-08-2024

PHP Code:
CodeIgniter\Database\Exceptions\DatabaseException #1064


You have an error in your SQL syntaxcheck the manual that corresponds to your MySQL server version for the right syntax to use near ') VALUES ('lelolenda', 'ee28491ff6eee15cd62888a7844aaddb', 'ruddstore@gmail.com'' at line 1 

$data = [
                    'nickname' => $db->escapeLikeString(strip_tags($request->getPost('nickname'))),
                    'password' => md5($request->getPost('password')),
                    'email' => $db->escapeLikeString(strtolower(strip_tags($request->getPost('email')))),
                    'email_token' => $token,
                    'password_token' => '',
                    'wallet' => 0,
                ];

                $model->insert($data);

the error debug finish at that lines

im using ci 4.4.4