|
|
|
|
@ -10,11 +10,11 @@ DELETE a.* FROM voip_usr_preferences a, voip_usr_preferences b
|
|
|
|
|
WHERE a.subscriber_id=b.subscriber_id
|
|
|
|
|
AND a.attribute_id=@old_nur_id AND b.attribute_id=@old_aur_id;
|
|
|
|
|
|
|
|
|
|
-- finally copy over the vars to the new preference
|
|
|
|
|
INSERT INTO voip_usr_preferences(subscriber_id, attribute_id, value)
|
|
|
|
|
SELECT p.subscriber_id, @new_pref_id, "never" from voip_usr_preferences p
|
|
|
|
|
WHERE p.attribute_id=@old_nur_id;
|
|
|
|
|
|
|
|
|
|
-- finally copy over the vars to the new preference
|
|
|
|
|
INSERT INTO voip_usr_preferences(subscriber_id, attribute_id, value)
|
|
|
|
|
SELECT p.subscriber_id, @new_pref_id, "ice_strip_candidates" from voip_usr_preferences p
|
|
|
|
|
WHERE p.attribute_id=@old_aur_id;
|
|
|
|
|
@ -24,10 +24,12 @@ SELECT id FROM voip_preferences WHERE attribute='always_use_ipv4_for_rtpproxy' I
|
|
|
|
|
SELECT id FROM voip_preferences WHERE attribute='always_use_ipv6_for_rtpproxy' INTO @old_pref_v6_id;
|
|
|
|
|
SELECT id FROM voip_preferences WHERE attribute='ipv46_for_rtpproxy' INTO @new_pref_id;
|
|
|
|
|
|
|
|
|
|
-- delete logically conflicting rows - ipv4 takes precedence
|
|
|
|
|
DELETE a.* FROM voip_usr_preferences a, voip_usr_preferences b
|
|
|
|
|
WHERE a.subscriber_id=b.subscriber_id
|
|
|
|
|
AND a.attribute_id=@old_pref_v6_id AND b.attribute_id=@old_pref_v4_id;
|
|
|
|
|
|
|
|
|
|
-- finally copy over the vars to the new preference
|
|
|
|
|
INSERT INTO voip_usr_preferences(subscriber_id, attribute_id, value)
|
|
|
|
|
SELECT p.subscriber_id, @new_pref_id, "force_ipv4" from voip_usr_preferences p
|
|
|
|
|
WHERE p.attribute_id=@old_pref_v4_id;
|
|
|
|
|
|