eugeneb 50 Posted May 10, 2019 Report Share Posted May 10, 2019 Hi guys, I am constantly getting this error when loggin in: Error Code: 500Error Message: CDbCommand failed to execute the SQL statement: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'elm9195d06e0vuqsliq8trpbs7' for key 'PRIMARY'Stack Trace: [click to toggle display]X2Engine Version: 7.1PHP Version: 5.6.25 Anyone else have it. or maybe a existing solution. I searched but couldn't find anything. Quote Link to post Share on other sites
jack 29 Posted May 10, 2019 Report Share Posted May 10, 2019 Can you upload the rest of the stack trace?Also that seems like a x2_sessions issue, I would delete the records on "x2_sessions" table and the "x2_sessions_token" table. And clear your X2 cookies for good measure. 1 Quote Link to post Share on other sites
eugeneb 50 Posted May 17, 2019 Author Report Share Posted May 17, 2019 Hi Jack, I will upload the stack trace when it happens again. Doesn't always do. While I await another incident, can it be due to me logging into various X2 instances on one machine? Quote Link to post Share on other sites
emmalone 5 Posted December 18, 2019 Report Share Posted December 18, 2019 Hello, I get a similar issue when creating or editing a template email. Any help would be appreciated. Error Code: 500Error Message: CDbCommand failed to execute the SQL statement: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'x2engine.x2_info_docs' doesn't existStack Trace: [click to toggle display]CDbException in /var/www/html/x2engine/framework/db/CDbCommand.php(543)#0 /var/www/html/x2engine/framework/db/CDbCommand.php(396): CDbCommand->queryInternal('fetchAll', Array, Array)#1 /var/www/html/x2engine/protected/modules/docs/models/Docs.php(118): CDbCommand->queryAll()#2 /var/www/html/x2engine/protected/modules/docs/models/Docs.php(109): Docs->infoDocCheck()#3 /var/www/html/x2engine/framework/db/ar/CActiveRecord.php(1132): Docs->afterSave()#4 /var/www/html/x2engine/protected/models/X2Model.php(904): CActiveRecord->update(NULL)#5 /var/www/html/x2engine/protected/modules/docs/controllers/DocsController.php(369): X2Model->save()#6 [internal function]: DocsController->actionUpdate('63')#7 /var/www/html/x2engine/framework/web/actions/CAction.php(109): ReflectionMethod->invokeArgs(Object(DocsController), Array)#8 /var/www/html/x2engine/framework/web/actions/CInlineAction.php(47): CAction->runWithParamsInternal(Object(DocsController), Object(ReflectionMethod), Array)#9 /var/www/html/x2engine/framework/web/CController.php(308): CInlineAction->runWithParams(Array)#10 /var/www/html/x2engine/framework/web/filters/CFilterChain.php(134): CController->runAction(Object(CInlineAction))#11 /var/www/html/x2engine/protected/controllers/x2base.php(586): CFilterChain->run()#12 /var/www/html/x2engine/framework/web/filters/CInlineFilter.php(58): x2base->filterSetPortlets(Object(CFilterChain))#13 /var/www/html/x2engine/framework/web/filters/CFilterChain.php(131): CInlineFilter->filter(Object(CFilterChain))#14 /var/www/html/x2engine/framework/web/filters/CFilter.php(40): CFilterChain->run()#15 /var/www/html/x2engine/framework/web/filters/CFilterChain.php(131): CFilter->filter(Object(CFilterChain))#16 /var/www/html/x2engine/framework/web/filters/CFilter.php(40): CFilterChain->run()#17 /var/www/html/x2engine/framework/web/filters/CFilterChain.php(131): CFilter->filter(Object(CFilterChain))#18 /var/www/html/x2engine/framework/web/CController.php(291): CFilterChain->run()#19 /var/www/html/x2engine/framework/web/CController.php(265): CController->runActionWithFilters(Object(CInlineAction), Array)#20 /var/www/html/x2engine/framework/web/CWebApplication.php(282): CController->run('update')#21 /var/www/html/x2engine/protected/components/X2WebApplication.php(65): CWebApplication->runController('docs/docs/updat...')#22 /var/www/html/x2engine/framework/base/CApplication.php(185): X2WebApplication->processRequest()#23 /var/www/html/x2engine/index.php(67): CApplication->run()#24 {main}X2Engine Version: 8.0PHP Version: 5.6.40 Quote Link to post Share on other sites
X2Clifton 7 Posted December 18, 2019 Report Share Posted December 18, 2019 Hi emmalone, Can you go to your /docs/models/Docs.php line 109 and comment out: $this->infoDocCheck(); and tell me if this fixes your issue? Quote Link to post Share on other sites
emmalone 5 Posted January 6, 2020 Report Share Posted January 6, 2020 Hello X2Clifton, Sorry for the slow reply. I had forgotten about this particular issue until it just happened again and in searching the forum landed on my own question. I just went to /x2engine/protected/modules/docs/models and that line does not exist in the Docs.php file. Any other suggestions would be appreciated. Thanks, Mark Quote Link to post Share on other sites
X2Clifton 7 Posted January 6, 2020 Report Share Posted January 6, 2020 Hi emmalone, Would you be able to tell me what is on line 109 of the Docs model? From your stack trace #3, it seems it's trying to call a function that shouldn't be called. Does the line I said to comment out not exist in the file at all? Quote Link to post Share on other sites
emmalone 5 Posted January 6, 2020 Report Share Posted January 6, 2020 Clifton, My apologies, I was in the wrong directory (old staging version of X2CRM) looking at the Docs.php. When I got to the right place, that line is there and once commented out, now the system acts as expected, no error. Thank you for your help. Mark 1 Quote Link to post Share on other sites
eugeneb 50 Posted January 7, 2020 Author Report Share Posted January 7, 2020 Hi Clifton, my bug on this originates from just logging into X2 and the dashboard then gives the error so I am not sure if its the same solution as Marks. His error was specific to the Doc module which you could help with. Here is my topic (at the top of this thread) http://community.x2crm.com/topic/3833-constant-error-500/?p=15676 Any chance you have a solution for mine? Thanks Quote Link to post Share on other sites
X2Clifton 7 Posted January 7, 2020 Report Share Posted January 7, 2020 Hi eugeneb, I will take a look! Have you been able to recreate it and obtain a stack trace from this error? Also, are you still running version 7.1? Quote Link to post Share on other sites
emmalone 5 Posted January 17, 2020 Report Share Posted January 17, 2020 Hello, I apologize if I confused this issue, because I agree it looks like my issue was different than Eugene's. But now I believe that I am having the same issue. I cleared the sessions and sessions_token tables and I am still getting the error. Here is the trace. Error Code: 500Error Message: CDbCommand failed to execute the SQL statement: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'jepu7auus6grfbk09il6aq6rd7' for key 'PRIMARY'Stack Trace: [click to toggle display] CDbException in /var/www/html/X2CRM-master/x2engine/framework/db/CDbCommand.php(358) #0 /var/www/html/X2CRM-master/x2engine/framework/db/ar/CActiveRecord.php(1083): CDbCommand->execute() #1 /var/www/html/X2CRM-master/x2engine/framework/db/ar/CActiveRecord.php(811): CActiveRecord->insert(NULL) #2 /var/www/html/X2CRM-master/x2engine/protected/components/behaviors/CommonSiteControllerBehavior.php(232): CActiveRecord->save() #3 [internal function]: CommonSiteControllerBehavior->login(Object(LoginForm)) #4 /var/www/html/X2CRM-master/x2engine/framework/base/CComponent.php(261): call_user_func_array(Array, Array) #5 /var/www/html/X2CRM-master/x2engine/protected/controllers/SiteController.php(1656): CComponent->__call('login', Array) #6 /var/www/html/X2CRM-master/x2engine/protected/controllers/SiteController.php(1656): SiteController->login(Object(LoginForm)) #7 /var/www/html/X2CRM-master/x2engine/framework/web/actions/CInlineAction.php(49): SiteController->actionLogin() #8 /var/www/html/X2CRM-master/x2engine/framework/web/CController.php(308): CInlineAction->runWithParams(Array) #9 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilterChain.php(134): CController->runAction(Object(CInlineAction)) #10 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilter.php(40): CFilterChain->run() #11 /var/www/html/X2CRM-master/x2engine/framework/web/CController.php(1148): CFilter->filter(Object(CFilterChain)) #12 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CInlineFilter.php(58): CController->filterAccessControl(Object(CFilterChain)) #13 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilterChain.php(131): CInlineFilter->filter(Object(CFilterChain)) #14 /var/www/html/X2CRM-master/x2engine/protected/controllers/x2base.php(586): CFilterChain->run() #15 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CInlineFilter.php(58): x2base->filterSetPortlets(Object(CFilterChain)) #16 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilterChain.php(131): CInlineFilter->filter(Object(CFilterChain)) #17 /var/www/html/X2CRM-master/x2engine/protected/controllers/x2base.php(586): CFilterChain->run() #18 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CInlineFilter.php(58): x2base->filterSetPortlets(Object(CFilterChain)) #19 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilterChain.php(131): CInlineFilter->filter(Object(CFilterChain)) #20 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilter.php(40): CFilterChain->run() #21 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilterChain.php(131): CFilter->filter(Object(CFilterChain)) #22 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilter.php(40): CFilterChain->run() #23 /var/www/html/X2CRM-master/x2engine/framework/web/filters/CFilterChain.php(131): CFilter->filter(Object(CFilterChain)) #24 /var/www/html/X2CRM-master/x2engine/framework/web/CController.php(291): CFilterChain->run() #25 /var/www/html/X2CRM-master/x2engine/framework/web/CController.php(265): CController->runActionWithFilters(Object(CInlineAction), Array) #26 /var/www/html/X2CRM-master/x2engine/framework/web/CWebApplication.php(282): CController->run('login') #27 /var/www/html/X2CRM-master/x2engine/protected/components/X2WebApplication.php(66): CWebApplication->runController('site/login') #28 /var/www/html/X2CRM-master/x2engine/framework/base/CApplication.php(185): X2WebApplication->processRequest() #29 /var/www/html/X2CRM-master/x2engine/index.php(68): CApplication->run() #30 {main}X2Engine Version: 8.0PHP Version: 5.6.40 Thanks, Mark Quote Link to post Share on other sites
X2Clifton 7 Posted January 17, 2020 Report Share Posted January 17, 2020 Hi emmalone, Would you also be able to clear the x2_session_log on top of the other two and check if that resolves the problem? Quote Link to post Share on other sites
emmalone 5 Posted January 17, 2020 Report Share Posted January 17, 2020 Clifton, I just cleared that table. I logged in with no error. I will let you know if it happens again. This has been an intermittent issue. Thanks, Mark 1 Quote Link to post Share on other sites
urthllc 0 Posted August 26, 2020 Report Share Posted August 26, 2020 I'm having this same issue I think, I created a new post so as not to highjack this thread in case they are different issues. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.