Advertisement
Guest User

error report craft

a guest
Mar 17th, 2016
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MySQL 6.10 KB | None | 0 0
  1. CDbException
  2.  
  3. CDbCommand failed to execute the SQL statement: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'COLLATE=' at line 8. The SQL statement executed was: CREATE TABLE `craft_matrixcontent_asdfsdfsdfasdf` (
  4. `id` int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY,
  5. `elementId` INT(11) NOT NULL,
  6. `locale` CHAR(12) NOT NULL,
  7. `dateCreated` datetime NOT NULL,
  8. `dateUpdated` datetime NOT NULL,
  9. `uid` CHAR(36) NOT NULL DEFAULT 0
  10. ) ENGINE=InnoDb DEFAULT CHARSET= COLLATE=
  11.  
  12. /sites/thales_website/craft/app/framework/db/CDbCommand.php(358)
  13.  
  14. 346         {
  15. 347             if($this->_connection->enableProfiling)
  16. 348                 Yii::endProfile('system.db.CDbCommand.execute('.$this->getText().$par.')','system.db.CDbCommand.execute');
  17. 349
  18. 350             $errorInfo=$e instanceof PDOException ? $e->errorInfo : null;
  19. 351             $message=$e->getMessage();
  20. 352             Yii::log(Yii::t('yii','CDbCommand::execute() failed: {error}. The SQL statement executed was: {sql}.',
  21. 353                 array('{error}'=>$message, '{sql}'=>$this->getText().$par)),CLogger::LEVEL_ERROR,'system.db.CDbCommand');
  22. 354
  23. 355             if(YII_DEBUG)
  24. 356                 $message.='. The SQL statement executed was: '.$this->getText().$par;
  25. 357
  26. 358             throw new CDbException(Yii::t('yii','CDbCommand failed to execute the SQL statement: {error}',
  27. 359                 array('{error}'=>$message)),(int)$e->getCode(),$errorInfo);
  28. 360         }
  29. 361     }
  30. 362
  31. 363     /**
  32. 364      * Executes the SQL statement and returns query result.
  33. 365      * This method is for executing an SQL query that returns result set.
  34. 366      * @param array $params input parameters (name=>value) for the SQL execution. This is an alternative
  35. 367      * to {@link bindParam} and {@link bindValue}. If you have multiple input parameters, passing
  36. 368      * them in this way can improve the performance. Note that if you pass parameters in this way,
  37. 369      * you cannot bind parameters or values using {@link bindParam} or {@link bindValue}, and vice versa.
  38. 370      * Please also note that all values are treated as strings in this case, if you need them to be handled as
  39. Stack Trace
  40. #0 
  41. +  /sites/thales_website/craft/app/framework/db/CDbCommand.php(1352): CDbCommand->execute()
  42. #1 
  43. –  /sites/thales_website/craft/app/etc/db/DbCommand.php(507): CDbCommand->createTable("craft_matrixcontent_asdfsdfsdfasdf", array("id" => "pk", "elementId" => "INT(11) NOT NULL", "locale" => "CHAR(12) NOT NULL", "dateCreated" => "datetime NOT NULL", ...), null)
  44. 502         {
  45. 503             $columns[$col] = DbHelper::generateColumnDefinition($settings);
  46. 504         }
  47. 505
  48. 506         // Create the table
  49. 507         return parent::createTable($table, $columns, $options);
  50. 508     }
  51. 509
  52. 510     /**
  53. 511      * @param $table
  54. 512      * @param $newName
  55. #2 
  56. –  /sites/thales_website/craft/app/services/MatrixService.php(1073): Craft\DbCommand->createTable("matrixcontent_asdfsdfsdfasdf", array("elementId" => array("column" => "integer", "null" => false), "locale" => array("column" => "locale", "null" => false)))
  57. 1068     private function _createContentTable($name)
  58. 1069     {
  59. 1070         craft()->db->createCommand()->createTable($name, array(
  60. 1071             'elementId' => array('column' => ColumnType::Int, 'null' => false),
  61. 1072             'locale'    => array('column' => ColumnType::Locale, 'null' => false)
  62. 1073         ));
  63. 1074
  64. 1075         craft()->db->createCommand()->createIndex($name, 'elementId,locale', true);
  65. 1076         craft()->db->createCommand()->addForeignKey($name, 'elementId', 'elements', 'id', 'CASCADE', null);
  66. 1077         craft()->db->createCommand()->addForeignKey($name, 'locale', 'locales', 'locale', 'CASCADE', 'CASCADE');
  67. 1078     }
  68. #3 
  69. –  /sites/thales_website/craft/app/services/MatrixService.php(535): Craft\MatrixService->_createContentTable("matrixcontent_asdfsdfsdfasdf")
  70. 530                     {
  71. 531                         MigrationHelper::renameTable($oldContentTable, $newContentTable);
  72. 532                     }
  73. 533                     else
  74. 534                     {
  75. 535                         $this->_createContentTable($newContentTable);
  76. 536                     }
  77. 537                 }
  78. 538
  79. 539                 // Delete the old block types first, in case there's a handle conflict with one of the new ones
  80. 540                 $oldBlockTypes = $this->getBlockTypesByFieldId($matrixField->id);
  81. #4 
  82. +  /sites/thales_website/craft/app/fieldtypes/MatrixFieldType.php(152): Craft\MatrixService->saveSettings(Craft\MatrixSettingsModel, false)
  83. #5 
  84. +  /sites/thales_website/craft/app/services/FieldsService.php(646): Craft\MatrixFieldType->onAfterSave()
  85. #6 
  86. +  /sites/thales_website/craft/app/controllers/FieldsController.php(122): Craft\FieldsService->saveField(Craft\FieldModel)
  87. #7 
  88. +  /sites/thales_website/craft/app/framework/web/actions/CInlineAction.php(49): Craft\FieldsController->actionSaveField()
  89. #8 
  90. +  /sites/thales_website/craft/app/framework/web/CController.php(308): CInlineAction->runWithParams(array("p" => "admin/settings/fields/new"))
  91. #9 
  92. +  /sites/thales_website/craft/app/framework/web/CController.php(286): CController->runAction(CInlineAction)
  93. #10
  94. +  /sites/thales_website/craft/app/framework/web/CController.php(265): CController->runActionWithFilters(CInlineAction, array())
  95. #11
  96. +  /sites/thales_website/craft/app/framework/web/CWebApplication.php(282): CController->run("saveField")
  97. #12
  98. +  /sites/thales_website/craft/app/etc/web/WebApp.php(815): CWebApplication->runController("fields/saveField")
  99. #13
  100. +  /sites/thales_website/craft/app/etc/web/WebApp.php(285): Craft\WebApp->_processActionRequest()
  101. #14
  102. +  /sites/thales_website/craft/app/framework/base/CApplication.php(185): Craft\WebApp->processRequest()
  103. #15
  104. +  /sites/thales_website/craft/app/index.php(62): CApplication->run()
  105. #16
  106. +  /sites/thales_website/public/index.php(21): require_once("/sites/thales_website/craft/app/index.php")
  107. 2016-03-17 08:19:16 Apache/2.4.16 (Unix) PHP/5.6.17 / Craft 2.6.2776
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement