Getting below error, please suggest:

DB Error #1062
[INSERT INTO ost_config SET namespace = 'core', key = 'client_avatar', value = 'gravatar.mm', updated = NOW()]

Entrada '0' duplicada para a chave 'PRIMARY'<br />
<br />
---- Backtrace ----<br />
#0 D:\filesdirectory\include\mysqli.php(201): osTicket->logDBError('DB Error #1062', '[INSERT INTO o...')<br />
#1 D:\filesdirectory\include\class.orm.php(3466): db_query('INSERT INTO
os...', true, true)<br />
#2 D:\filesdirectory\include\class.orm.php(658): MySqlExecutor->execute()<br />
#3 D:\filesdirectory\include\class.config.php(173): VerySimpleModel->save(true)<br />
#4 D:\filesdirectory\include\class.config.php(106): ConfigItem->save()<br />
#5 D:\filesdirectory\include\class.config.php(116): Config->create('client_avatar', 'gravatar.mm')<br />
#6 D:\filesdirectory\include\class.config.php(132): Config->update('client_avatar', 'gravatar.mm')<br />
#7 D:\filesdirectory\include\class.config.php(1360): Config->updateAll(Array)<br />
#8 D:\filesdirectory\include\class.config.php(1208): OsticketConfig->updateUsersSettings(Array, Array)<br />
#9 D:\filesdirectory\scp\settings.php(42): OsticketConfig->updateSettings(Array, Array)<br />
#10 {main}

DB Error #1062
[INSERT INTO ost_ticket SET created = NOW(), lastupdate = NOW(), number = '100225', user_id = 81, dept_id = 1, topic_id = 10, ip_address = 'xxx.xxx.xxx.xxx', source = 'Web', updated = NOW()]

Entrada '0' duplicada para a chave 'PRIMARY'<br />
<br />
---- Backtrace ----<br />
#0 D:\filesdirectory\include\mysqli.php(201): osTicket->logDBError('DB Error #1062', '[INSERT INTO o...')<br />
#1 D:\filesdirectory\include\class.orm.php(3466): db_query('INSERT INTO
os...', true, true)<br />
#2 D:\filesdirectory\include\class.orm.php(658): MySqlExecutor->execute()<br />
#3 D:\filesdirectory\include\class.ticket.php(3637): VerySimpleModel->save(true)<br />
#4 D:\filesdirectory\include\class.ticket.php(4322): Ticket->save()<br />
#5 D:\filesdirectory\open.php(45): Ticket::create(Array, Array, 'Web')<br />
#6 {main}

DB Error #1062
[INSERT INTO ost_draft SET namespace = 'ticket.response.783', body = '<p><br></p>', created = NOW(), staff_id = 3]

Entrada '0' duplicada para a chave 'PRIMARY'<br />
<br />
---- Backtrace ----<br />
#0 D:\filesdirectory\include\mysqli.php(201): osTicket->logDBError('DB Error #1062', '[INSERT INTO o...')<br />
#1 D:\filesdirectory\include\class.orm.php(3466): db_query('INSERT INTO
os...', true, true)<br />
#2 D:\filesdirectory\include\class.orm.php(658): MySqlExecutor->execute()<br />
#3 D:\filesdirectory\include\class.draft.php(140): VerySimpleModel->save(false)<br />
#4 D:\filesdirectory\include\ajax.draft.php(16): Draft->save()<br />
#5 D:\filesdirectory\include\ajax.draft.php(261): DraftAjaxAPI->_createDraft(Array)<br />
#6 [internal function]: DraftAjaxAPI->createDraft('ticket.response...')<br />
#7 D:\filesdirectory\include\class.dispatcher.php(145): call_user_func_array(Array, Array)<br />
#8 D:\filesdirectory\include\class.dispatcher.php(38): UrlMatcher->dispatch('ticket.response...', Array)<br />
#9 D:\filesdirectory\include\class.dispatcher.php(120): Dispatcher->resolve('ticket.response...', Array)<br />
#10 D:\filesdirectory\include\class.dispatcher.php(38): UrlMatcher->dispatch('/draft/ticket.r...', NULL)<br />
#11 D:\filesdirectory\scp\ajax.php(314): Dispatcher->resolve('/draft/ticket.r...')<br />
#12 {main}

DB Error #1062
[INSERT INTO ost_thread_entry SET created = NOW(), type = 'R', thread_id = 1030, format = 'html', staff_id = 3, poster = 'Daniel', flags = 576, recipients = '{\"to\":{\"80\":\"Taris xxxxxxxxx@gmail.com\"}}', pid = 3481, ip_address = 'xxxxxxxxxxx', body = '<p>Atualização feita. </p>']

Entrada '0' duplicada para a chave 'PRIMARY'<br />
<br />
---- Backtrace ----<br />
#0 D:\filesdirectory\include\mysqli.php(201): osTicket->logDBError('DB Error #1062', '[INSERT INTO o...')<br />
#1 D:\filesdirectory\include\class.orm.php(3466): db_query('INSERT INTO
os...', true, true)<br />
#2 D:\filesdirectory\include\class.orm.php(658): MySqlExecutor->execute()<br />
#3 D:\filesdirectory\include\class.thread.php(1794): VerySimpleModel->save(true)<br />
#4 D:\filesdirectory\include\class.thread.php(1810): ThreadEntry::create(Array)<br />
#5 D:\filesdirectory\include\class.thread.php(2984): ThreadEntry::add(Array)<br />
#6 D:\filesdirectory\include\class.thread.php(3167): ResponseThreadEntry::add(Array, Array)<br />
#7 D:\filesdirectory\include\class.ticket.php(3330): ObjectThread->addResponse(Array, Array)<br />
#8 D:\filesdirectory\scp\tickets.php(214): Ticket->postReply(Array, Array, 13)<br />
#9 {main}

DB Error #1062
[INSERT INTO ost_config SET namespace = 'core', key = 'client_avatar', value = 'gravatar.mm', updated = NOW()]

Entrada '0' duplicada para a chave 'PRIMARY'<br />
<br />
---- Backtrace ----<br />
#0 D:\filesdirectory\include\mysqli.php(201): osTicket->logDBError('DB Error #1062', '[INSERT INTO o...')<br />
#1 D:\filesdirectory\include\class.orm.php(3466): db_query('INSERT INTO
os...', true, true)<br />
#2 D:\filesdirectory\include\class.orm.php(658): MySqlExecutor->execute()<br />
#3 D:\filesdirectory\include\class.config.php(173): VerySimpleModel->save(true)<br />
#4 D:\filesdirectory\include\class.config.php(106): ConfigItem->save()<br />
#5 D:\filesdirectory\include\class.config.php(116): Config->create('client_avatar', 'gravatar.mm')<br />
#6 D:\filesdirectory\include\class.config.php(132): Config->update('client_avatar', 'gravatar.mm')<br />
#7 D:\filesdirectory\include\class.config.php(1360): Config->updateAll(Array)<br />
#8 D:\filesdirectory\include\class.config.php(1208): OsticketConfig->updateUsersSettings(Array, Array)<br />
#9 D:\filesdirectory\scp\settings.php(42): OsticketConfig->updateSettings(Array, Array)<br />
#10 {main}

DB Error #1062
[INSERT INTO ost_config SET namespace = 'core', key = 'client_avatar', value = 'gravatar.mm', updated = NOW()]

Entrada '0' duplicada para a chave 'PRIMARY'<br />
<br />
---- Backtrace ----<br />
#0 D:\filesdirectory\include\mysqli.php(201): osTicket->logDBError('DB Error #1062', '[INSERT INTO o...')<br />
#1 D:\filesdirectory\include\class.orm.php(3466): db_query('INSERT INTO
os...', true, true)<br />
#2 D:\filesdirectory\include\class.orm.php(658): MySqlExecutor->execute()<br />
#3 D:\filesdirectory\include\class.config.php(173): VerySimpleModel->save(true)<br />
#4 D:\filesdirectory\include\class.config.php(106): ConfigItem->save()<br />
#5 D:\filesdirectory\include\class.config.php(116): Config->create('client_avatar', 'gravatar.mm')<br />
#6 D:\filesdirectory\include\class.config.php(132): Config->update('client_avatar', 'gravatar.mm')<br />
#7 D:\filesdirectory\include\class.config.php(1360): Config->updateAll(Array)<br />
#8 D:\filesdirectory\include\class.config.php(1208): OsticketConfig->updateUsersSettings(Array, Array)<br />
#9 D:\filesdirectory\scp\settings.php(42): OsticketConfig->updateSettings(Array, Array)<br />
#10 {main}

    9 days later

    taris

    You are running osTicket 1.14.x which requires PHP 7.0-7.2. Please upgrade PHP, restart IIS, and retest.

    Cheers.

    2 months later

    Sorry I have same problem. System create new tickets but I can't open last tickets of today. I've seen that there is recurrent error: Databse error #1062. Can you help me? Thank you so much!

    Informazioni sul server
    Versione osTicket v1.14.3 (f4f5bc6) — v1.14.8 è disponibile
    Web Server Software Apache
    Versione MySQL 10.5.13
    Versione PHP 7.4.27
    Estensioni PHP
    gdlib Utilizzato per la manipolazione delle immagini e stampa PDF
    imap Usata per il fetching mail
    xml API XML
    xml-dom Utilizzato per l'elaborazione di e-mail HTML
    json Migliora le prestazioni di creazione ed elaborazione di JSON
    mbstring Altamente raccomandato per contenuti in lingua dell'est europa
    phar Altamente raccomandato per plugin e language packs
    intl Altamente raccomandato per contenuti in lingua dell'est europa
    fileinfo Usato per rilevare i tipi di file in upload
    zip Used for ticket and task exporting
    APCu Migliora le performace globali
    Zend Opcache Migliora le performace globali
    Impostazioni PHP
    cgi.fix_pathinfo "1" è consigliato se l'AJAX non funziona
    date.timezone Europe/Rome
    Informazioni uso del Database
    Schema osticket_Inter_ (localhost:3306)
    Firma Schema 4bd47d94b10bd8a6bab35c119dadf41f
    Spazio utilizzato 45.73 MiB
    Spazio per allegati 38.52 MiB
    Fuso orario CET (Interpretato come Europe/Berlin)

    DB Error #1062
    [INSERT INTO osticket_Inter_thread_referral SET thread_id = 122, object_id = 7, object_type = 'D', created = NOW()] Duplicate entry '7-D-122' for key 'ref'

    ---- Backtrace ----
    #0 (root)/include/mysqli.php(200): osTicket->logDBError()
    #1 (root)/include/class.orm.php(3466): db_query()
    #2 (root)/include/class.orm.php(658): MySqlExecutor->execute()
    #3 (root)/include/class.thread.php(1952): VerySimpleModel->save()
    #4 (root)/include/class.thread.php(380): ThreadReferral::create()
    #5 (root)/include/class.ticket.php(2517): Thread->refer()
    #6 (root)/include/class.ticket.php(2535): Ticket::manageMerge()
    #7 (root)/include/ajax.tickets.php(431): Ticket::merge()
    #8 (root)/include/class.dispatcher.php(145): TicketsAjaxAPI->updateMerge()
    #9 (root)/include/class.dispatcher.php(38): UrlMatcher->dispatch()
    #10 (root)/include/class.dispatcher.php(120): Dispatcher->resolve()
    #11 (root)/include/class.dispatcher.php(38): UrlMatcher->dispatch()
    #12 (root)/scp/ajax.php(314): Dispatcher->resolve()
    #13 {main}

      Intermediaction
      Have you been able to solve the issue?
      I recently updated as well and it takes too long to open old tickets for viewing .it sometimes open or comes up
      with an error message

      Write a Reply...