# Fehler: SQLSTATE\[23000\]:Integrity constraint violation: 1062

**URL:** <https://forum.shopware.com/t/fehler-sqlstate-23000-integrity-constraint-violation-1062/22354>\
**Category:** Shopware 3.5\
**Tags:** other\
**Created:** [10. September 2014 um 16:49 UTC](https://forum.shopware.com/t/fehler-sqlstate-23000-integrity-constraint-violation-1062/22354 "2014-09-10T16:49:21Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![andreas.olf](https://avatars.discourse-cdn.com/v4/letter/a/ec9cab/32.png) [@andreas.olf](https://forum.shopware.com/u/andreas.olf)\
**Post date:** [10. September 2014 um 16:49 UTC](https://forum.shopware.com/t/fehler-sqlstate-23000-integrity-constraint-violation-1062/22354/1 "2014-09-10T16:49:21Z")

</div>

Hallo, ich bin noch in der Testphase für meinen Shop (4.3.0). Habe die ersten Test-Bestellungen problemlos durchführen können. Seit kurzem erhalte ich bei der cron-Durchführung die Fehlermeldung: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‚Shopware\_CronJob\_DocumentCreate‘ for key ‚action‘ in Zend/Db/Statement/Pdo.php on line 234 Stack trace: #0 Zend/Db/Statement.php(303): Zend\_Db\_Statement\_Pdo-\>\_execute(Array) #1 Zend/Db/Adapter/Abstract.php(480): Zend\_Db\_Statement-\>execute(Array) #2 Zend/Db/Adapter/Pdo/Abstract.php(238): Zend\_Db\_Adapter\_Abstract-\>query(‚UPDATE `s_cront...', Array) #3 Enlight/Components/Db/Adapter/Pdo/Mysql.php(75): Zend_Db_Adapter_Pdo_Abstract-\>query('UPDATE `s\_cront…‘, Array) #4 Zend/Db/Adapter/Abstract.php(635): Enlight\_Components\_Db\_Adapter\_Pdo\_Mysql-\>query(‚UPDATE `s\_cront…‘, Array) #5 Zend/Db/Table/Abstract.php(1133): Zend\_Db\_Adapter\_Abstract-\>update(‚s\_crontab‘, Array, Array) #6 Enlight/Components/Cron/Adapter/DbTable.php(153): Zend\_Db\_Table\_Abstract-\>update(Array, Array) #7 Enlight/Components/Cron/Manager.php(119): Enlight\_Components\_Cron\_Adapter\_DbTable-\>updateJob(Object(Enlight\_Components\_Cron\_Job)) #8 Enlight/Components/Cron/Manager.php(238): Enlight\_Components\_Cron\_Manager-\>disableJob(Object(Enlight\_Components\_Cron\_Job)) #9 Shopware/Plugins/Default/Core/Cron/Cron.php(60): Enlight\_Components\_Cron\_Manager-\>runJob(Object(Enlight\_Components\_Cron\_Job)) #10 Enlight/Controller/Action.php(159): Shopware\_Controllers\_Backend\_Cron-\>indexAction() #11 Enlight/Controller/Dispatcher/Default.php(528): Enlight\_Controller\_Action-\>dispatch(‚indexAction‘) #12 Enlight/Controller/Front.php(228): Enlight\_Controller\_Dispatcher\_Default-\>dispatch(Object(Enlight\_Controller\_Request\_RequestHttp), Object(Enlight\_Controller\_Response\_ResponseHttp)) #13 Shopware/Kernel.php(141): Enlight\_Controller\_Front-\>dispatch() #14 vendor/symfony/http-kernel/Symfony/Component/HttpKernel/HttpCache/HttpCache.php(472): Shopware\Kernel-\>handle(Object(Symfony\Component\HttpFoundation\Request), 1, true) #15 Shopware/Components/HttpCache/AppCache.php(256): Symfony\Component\HttpKernel\HttpCache\HttpCache-\>forward(Object(Symfony\Component\HttpFoundation\Request), true, NULL) #16 vendor/symfony/http-kernel/Symfony/Component/HttpKernel/HttpCache/HttpCache.php(243): Shopware\Components\HttpCache\AppCache-\>forward(Object(Symfony\Component\HttpFoundation\Request), true) #17 Shopware/Components/HttpCache/AppCache.php(102): Symfony\Component\HttpKernel\HttpCache\HttpCache-\>pass(Object(Symfony\Component\HttpFoundation\Request), true) #18 shopware.php(109): Shopware\Components\HttpCache\AppCache-\>handle(Object(Symfony\Component\HttpFoundation\Request)) #19 {main} ----------- Woran könnte das liegen?

---

<div class="post-metadata">

**Author:** ![Moritz\_Naczenski](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/moritz_naczenski/32/7792_2.png) [@Moritz\_Naczenski](https://forum.shopware.com/u/Moritz_Naczenski)\
**Post date:** [11. September 2014 um 08:06 UTC](https://forum.shopware.com/t/fehler-sqlstate-23000-integrity-constraint-violation-1062/22354/2 "2014-09-11T08:06:24Z")

</div>

Hallo, der Fehler tritt in der Regel auf, wenn der Cronjob doppelt angelegt ist. Schau mal unter [Einstellungen \> Grundeinstellungen \> System \> Cronjobs] nach ob es zweimal den gleichen Cronjob („DocumentCreate“) gibt. Sollte dies der Fall sein, so kannst du dort einen von beiden löschen. Ein häufiger Fehler der zu diesem Problem führt, sind Plugins die bei einer erneuten Installation den Cronjob einfach nochmal anlegen, statt zu überprüfen ob er schon existiert. Grüße Moritz
