--CRM-13446, fixed Upgrade code for fatal error if civicrm_financial_account.contact_...
authorPradeep Nayak <pradeep@pradeep.(none)>
Wed, 25 Sep 2013 10:02:31 +0000 (15:32 +0530)
committerPradeep Nayak <pradeep@pradeep.(none)>
Wed, 25 Sep 2013 10:02:31 +0000 (15:32 +0530)
----------------------------------------
* CRM-13446: Add ON DELETE Options for constraints fails
  http://issues.civicrm.org/jira/browse/CRM-13446

CRM/Upgrade/Incremental/php/FourThree.php

index a925a615b32a1c0b6bd65b1683256c3ea16dfbe3..75d44e49dac3c72e52624ece6668a5db12def09e 100644 (file)
@@ -1101,6 +1101,7 @@ AND cli.entity_table = 'civicrm_contribution' AND cli.id IN (" . implode(',', $v
    * @return bool TRUE for success
    */
   function task_4_3_x_checkConstraints(CRM_Queue_TaskContext $ctx) {
+    CRM_Core_DAO::executeQuery('ALTER TABLE `civicrm_financial_account` CHANGE `contact_id` `contact_id` INT( 10 ) UNSIGNED NULL DEFAULT NULL');
     $config = CRM_Core_Config::singleton();
     $dbname  = DB::parseDSN($config->dsn);
     $constraintArray = array(