commiting uncommited changes on live site
[weblabels.fsf.org.git] / crm.fsf.org / 20131203 / files / sites / all / modules-new / civicrm / CRM / Upgrade / Incremental / sql / 4.6.beta4.mysql.tpl
1 {* file to handle db changes in 4.6.beta4 during upgrade *}
2 -- CRM-14792
3 SELECT @option_group_id_act := max(id) from civicrm_option_group where name = 'activity_type';
4 SELECT @option_group_id_act_wt := MAX(weight) FROM civicrm_option_value WHERE option_group_id = @option_group_id_act;
5 SELECT @option_group_id_act_val := MAX(CAST( `value` AS UNSIGNED )) FROM civicrm_option_value WHERE option_group_id = @option_group_id_act;
6
7 INSERT INTO
8 `civicrm_option_value` (`option_group_id`, {localize field='label'}`label`{/localize}, `value`, `name`, `grouping`, `filter`, `is_default`, `weight`, {localize field='description'}`description`{/localize}, `is_optgroup`, `is_reserved`, `is_active`, `component_id`, `visibility_id`)
9 VALUES
10 (@option_group_id_act, {localize}'{ts escape="sql"}Contact Merged{/ts}'{/localize}, @option_group_id_act_val+1, 'Contact Merged', NULL, 1, NULL, @option_group_id_act_wt+1, {localize}'{ts escape="sql"}Contact Merged{/ts}'{/localize}, 0, 1, 1, NULL, NULL);