Register new user fatal Error February 05, 2019, 03:33:40 PM In classic , when going live and tried to register a new user, i get this.Fatal error: Uncaught PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'contest.Users' doesn't exist in /data/sites/web/xxx/www/contest/app/models/PDODb.php:1042 Stack trace: #0 /data/sites/web/xxx/www/contest/app/models/PDODb.php(1042): PDOStatement->execute() #1 /data/sites/web/xxx/www/contest/app/models/PDODb.php(1076): PDODb->get('Users', 1, '*') #2 /data/sites/web/xxx/www/contest/app/models/PDODb.php(951): PDODb->getOne('Users') #3 /data/sites/web/xxx/www/contest/app/controllers/IndexController.php(138): PDODb->has('Users') #4 /data/sites/web/xxx/www/contest/system/Router.php(227): IndexController->register() #5 /data/sites/web/xxx/www/contest/system/Router.php(92): Router->run('index/register') #6 /data/sites/web/xxx/www/contest/index.php(85): Router->init() #7 {main} thrown in /data/sites/web/xxx/www/contest/app/models/PDODb.php on line 1042my db is contestmy user table is : users and not Userson local, ( xampp ) it works fineWhat does it means ?Thanks Quote Selected
Re: Register new user fatal Error Reply #1 – February 05, 2019, 08:11:20 PM Here is the culprit...into indexController , the table name is modified and start with a Capital. On my local server it has no impact but online it has.So , if i change Users to users , it works online too. //Check if Duplicate Record Already Exit In The Database $db->where('accountname',$modeldata['accountname']); if($db->has('Users')){ $this->view->page_error[] = $modeldata['accountname']."Already exist!"; } //Check if Duplicate Record Already Exit In The Database $db->where('email',$modeldata['email']); if($db->has('Users')){ $this->view->page_error[] = $modeldata['email']."Already exist!"; } if( empty($this->view->page_error) ){ $rec_id = $db->insert('Users',$modeldata); if(!empty($rec_id)){ redirect_to_page("index/send_verify_email_link/$modeldata[email]"); return; }I don't know why the table name is modified when publishing project. It may be a bug.Can you please check this and advice.ThanksEroll Quote Selected
Re: Register new user fatal Error Reply #2 – February 08, 2019, 08:01:57 AM Normally SQL table and fields name are not case sensitive. I believe it must be a settings on the server.But we will put in check to use the actual database case.Thanks Quote Selected
Re: Register new user fatal Error Reply #3 – February 08, 2019, 03:27:48 PM Here , on my server ( shared one) it's define with Case Sensitive and cannot be change.Thanks to take care of this for the next release and in the meantime , if you have a workaround to avoid this, it will be great.I mean when publishing (Because i have to think about that on every publish )CheersEroll Quote Selected Last Edit: February 10, 2019, 08:24:52 AM by Eroll