XF 2.1 MySQL query error [1062]: Duplicate entry

Nirjonadda

Well-known member
Server error log.

Code:
XF\Db\DuplicateKeyException: MySQL query error [1062]: Duplicate entry 'Ziaul' for key 'username' src/XF/Db/AbstractStatement.php:217

Generated by: Unknown account May 4, 2019 at 4:58 AM

Stack trace

INSERT  INTO `xf_user` (`visible`, `activity_visible`, `user_group_id`, `timezone`, `language_id`, `username`, `email`, `user_state`, `privacy_policy_accepted`, `terms_accepted`, `dbtech_shop_purchase`, `display_style_group_id`, `secondary_group_ids`, `secret_key`, `user_id`, `style_id`, `permission_combination_id`, `message_count`, `alerts_unread`, `conversations_unread`, `register_date`, `last_activity`, `trophy_points`, `avatar_date`, `avatar_width`, `avatar_height`, `avatar_highdpi`, `gravatar`, `is_moderator`, `is_admin`, `is_staff`, `is_banned`, `reaction_score`, `custom_title`, `warning_points`, `xfmg_album_count`, `xfmg_media_count`, `xfmg_media_quota`, `snog_flag`, `dbtech_credits_credits`, `dbtech_credits_lastdaily`, `dbtech_credits_lastinterest`, `dbtech_credits_lastpaycheck`, `dbtech_credits_lasttaxation`, `dbtech_security_forcenewpass`, `dbtech_security_lastbreach`, `dbtech_security_breached`, `dbtech_shop_points`, `dbtech_shop_purchases`, `dbtech_shop_immunity`, `dbtech_shop_pendingtrades`, `dbtech_shop_item_count`, `true_last_activity`, `time_spent`, `thdonate_total_donation`, `thdonate_total_public_donation`, `thdonate_total_anonymous_donation`, `thdonate_num_donation`, `thdonate_num_public_donation`, `thdonate_num_anonymous_donation`, `dbtech_mail_defaultkeyword`, `dbtech_mail_inactivereminder`, `dbtech_mail_numreminders`, `dbtech_mail_newsletter_frequency`, `dbtech_mail_newsletter_receive`, `dbtech_mail_newsletter_lastreceive`, `dbtech_mail_validation_date`, `af_as_award_total`, `snog_forms`, `thtopics_topic_filters`, `thtopics_forum_filters`, `kl_em_wordcount_mode`, `siropu_referrer_id`, `siropu_referral_count`, `siropu_referrer_credit`, `thread_count`, `siropu_easy_user_ban_count`) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
------------

#0 src/XF/Db/Mysqli/Statement.php(196): XF\Db\AbstractStatement->getException('MySQL query err...', 1062, '23000')
#1 src/XF/Db/Mysqli/Statement.php(77): XF\Db\Mysqli\Statement->getException('MySQL query err...', 1062, '23000')
#2 src/XF/Db/AbstractAdapter.php(94): XF\Db\Mysqli\Statement->execute()
#3 src/XF/Db/AbstractAdapter.php(218): XF\Db\AbstractAdapter->query('INSERT  INTO `x...', Array)
#4 src/XF/Mvc/Entity/Entity.php(1452): XF\Db\AbstractAdapter->insert('xf_user', Array, false)
#5 src/XF/Mvc/Entity/Entity.php(1184): XF\Mvc\Entity\Entity->_saveToSource()
#6 src/XF/Service/User/Registration.php(279): XF\Mvc\Entity\Entity->save()
#7 src/XF/Service/ValidateAndSavableTrait.php(40): XF\Service\User\Registration->_save()
#8 src/XF/Pub/Controller/Register.php(419): XF\Service\User\Registration->save()
#9 src/addons/AddonFlare/PaidRegistrations/XF/Pub/Controller/Register.php(131): XF\Pub\Controller\Register->actionRegister()
#10 src/XF/Mvc/Dispatcher.php(321): AddonFlare\PaidRegistrations\XF\Pub\Controller\Register->actionRegister(Object(XF\Mvc\ParameterBag))
#11 src/XF/Mvc/Dispatcher.php(244): XF\Mvc\Dispatcher->dispatchClass('XF:Register', 'Register', Object(XF\Mvc\RouteMatch), Object(AddonFlare\PaidRegistrations\XF\Pub\Controller\Register), NULL)
#12 src/XF/Mvc/Dispatcher.php(100): XF\Mvc\Dispatcher->dispatchFromMatch(Object(XF\Mvc\RouteMatch), Object(AddonFlare\PaidRegistrations\XF\Pub\Controller\Register), NULL)
#13 src/XF/Mvc/Dispatcher.php(50): XF\Mvc\Dispatcher->dispatchLoop(Object(XF\Mvc\RouteMatch))
#14 src/XF/App.php(2177): XF\Mvc\Dispatcher->run()
#15 src/XF.php(390): XF\App->run()
#16 index.php(20): XF::runApp('XF\\Pub\\App')
#17 {main}

Request state

array(4) {
  ["url"] => string(18) "/register/register"
  ["referrer"] => string(46) "/register/?accountType=1"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(20) {
    ["username"] => string(0) ""
    ["46effe12c974a2ed5c3d79dcd506d549e82b6782"] => string(5) "Ziaul"
    ["ae68639ae0ea6ac10fc72ce299f38e132cd7ef73"] => string(0) ""
    ["9019c0ee50be353016d9bc6f52fac6cb5f7ea54b"] => string(19) "XXXX@gmail.com"
    ["password"] => string(8) "********"
    ["3bd3be5141e5bfc501be991e1a6f14e23e87e870"] => string(8) "********"
    ["dob_month"] => string(1) "1"
    ["dob_day"] => string(2) "21"
    ["dob_year"] => string(4) "1993"
    ["location"] => string(5) "Dhaka"
    ["custom_fields"] => array(2) {
      ["gender"] => string(4) "male"
      ["siropu_referrer"] => string(0) ""
    }
    ["g-recaptcha-response"] => string(356) "03AOLTBLSUm_w_TpLvIHAE9LZX647XNHN0y-unbSHLDT7pdQ61Yym2Dpi697vvWv4_Ki6yzPZwRlyCpp1BX4C06z1201I3VmhaykqPmhqhYGvypTKOX-zoCUivFKl04gPXHx3_dqLYJBzG5mmnsaHZfYXD1JfihdjObIVLER7S1p8CKmzsXRlqebXbSn2unUGNX2P9L0enBUJ5gVjRgjGkxU-pRieVAYSt84X7n6CkQorcdjczKJqaTnduIwyyVFCMPNG6py33YJwN1FNCxC_SFwQvJnAvL_ZNyFZTrqcECYBQ0Huh0yTTSp3_IkU6ky3CF1a1EzgmG9Ru80v8a58wS-MKAC7cS5AtQQ"
    ["email_choice"] => string(1) "1"
    ["accept"] => string(1) "1"
    ["reg_key"] => string(16) "wDvw_cb27hpN63cm"
    ["992981afbbfbe098d250b35a8eb97b679cf604de"] => string(10) "Asia/Dhaka"
    ["_xfToken"] => string(8) "********"
    ["_xfRequestUri"] => string(24) "/register/?accountType=1"
    ["_xfWithData"] => string(1) "1"
    ["_xfResponseType"] => string(4) "json"
  }
}
 
Back
Top Bottom