XF 2.1 Cant rebuild thread (XF\Db\Exception: MySQL query error [1265]:)

calopezes

Member
Rebuilding cache: I get this error.


XF\Db\Exception: MySQL query error [1265]: Data truncated for column 'position' at row 1 in src/XF/Db/AbstractStatement.php at line 217
  1. XF\Db\AbstractStatement->getException() insrc/XF/Db/Mysqli/Statement.php at line 196
  2. XF\Db\Mysqli\Statement->getException() insrc/XF/Db/Mysqli/Statement.php at line 77
  3. XF\Db\Mysqli\Statement->execute() in src/XF/Db/AbstractAdapter.phpat line 89
  4. XF\Db\AbstractAdapter->query() in src/XF/Repository/Thread.php at line336
  5. XF\Repository\Thread->rebuildThreadPostPositions() insrc/XF/Job/Thread.php at line 49
  6. XF\Job\Thread->rebuildById() in src/XF/Job/AbstractRebuildJob.php at line 47
  7. XF\Job\AbstractRebuildJob->run() in src/XF/Job/Manager.php at line253
  8. XF\Job\Manager->runJobInternal() in src/XF/Job/Manager.php at line195
  9. XF\Job\Manager->runJobEntry() in src/XF/Job/Manager.php at line 111
  10. XF\Job\Manager->runByIds() in src/XF/Admin/Controller/Tools.php at line 120
  11. XF\Admin\Controller\Tools->actionRunJob() insrc/XF/Mvc/Dispatcher.php at line 321
  12. XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line248
  13. XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.phpat line 100
  14. XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line50
  15. XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2177
  16. XF\App->run() in src/XF.php at line 390
  17. XF::runApp() in admin.php at line 13
 
The output is:

Code:
CREATE TABLE `xf_post` (
  `post_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  `thread_id` int(10) unsigned NOT NULL,
  `user_id` int(10) unsigned NOT NULL,
  `username` varchar(50) NOT NULL,
  `post_date` int(10) unsigned NOT NULL,
  `message` mediumtext NOT NULL,
  `ip_id` int(10) unsigned NOT NULL DEFAULT '0',
  `message_state` enum('visible','moderated','deleted') NOT NULL DEFAULT 'visible',
  `attach_count` smallint(5) unsigned NOT NULL DEFAULT '0',
  `position` int(10) unsigned NOT NULL,
  `reaction_score` int(11) NOT NULL DEFAULT '0',
  `reactions` blob,
  `reaction_users` blob NOT NULL,
  `warning_id` int(10) unsigned NOT NULL DEFAULT '0',
  `warning_message` varchar(255) NOT NULL DEFAULT '',
  `last_edit_date` int(10) unsigned NOT NULL DEFAULT '0',
  `last_edit_user_id` int(10) unsigned NOT NULL DEFAULT '0',
  `edit_count` int(10) unsigned NOT NULL DEFAULT '0',
  `embed_metadata` blob,
  PRIMARY KEY (`post_id`),
  KEY `thread_id_post_date` (`thread_id`,`post_date`),
  KEY `thread_id_position` (`thread_id`,`position`),
  KEY `user_id` (`user_id`),
  KEY `post_date` (`post_date`)
) ENGINE=InnoDB AUTO_INCREMENT=23801513 DEFAULT CHARSET=utf8
 
That's certainly odd and I can't see any reason for it -- I believe it would require a thread to have 4 billion posts in it to trigger that. :)

Would it be possible for you to submit a ticket with admin control panel access details and FTP (or similar) information so we can reproduce the issue and debug it? (Please reference this thread when creating the ticket.)
 
Top Bottom