Fix event contribution_type FK error CRM-12312
authorColeman Watts <coleman@civicrm.org>
Tue, 9 Apr 2013 22:30:45 +0000 (15:30 -0700)
committerColeman Watts <coleman@civicrm.org>
Tue, 9 Apr 2013 22:30:45 +0000 (15:30 -0700)
CRM/Upgrade/Incremental/sql/4.3.alpha1.mysql.tpl

index d5c0b9d0e1a9e8a1ff189836e7eb64ee23067443..65dbcf0f16dddaa48c282996e344741f1e351766 100644 (file)
@@ -291,7 +291,10 @@ ALTER TABLE `civicrm_financial_item`
 ALTER TABLE `civicrm_entity_financial_trxn`
 DROP currency;
 
--- CRM 9189 and CRM-8425 change fk's to financial_account.id in our branch that will need to be changed to an fk to financial_type.id
+-- CRM-12312
+UPDATE civicrm_event SET contribution_type_id = NULL WHERE contribution_type_id = 0;
+
+-- CRM-9189 and CRM-8425 change fk's to financial_account.id in our branch that will need to be changed to an fk to financial_type.id
 
 ALTER TABLE `civicrm_pledge`
 DROP FOREIGN KEY FK_civicrm_pledge_contribution_type_id,