Commit b59609cc authored by Günther Niess's avatar Günther Niess Committed by niess

OF-73: Fix DB upgrade from OF3.5 for MS SQL Server

git-svn-id: http://svn.igniterealtime.org/svn/repos/openfire/trunk@11489 b35dd754-fafc-0310-a699-88a17e54d16e
parent 3907f0a5
...@@ -28,12 +28,16 @@ INSERT INTO mucService (serviceID, subdomain) VALUES (1, 'conference'); ...@@ -28,12 +28,16 @@ INSERT INTO mucService (serviceID, subdomain) VALUES (1, 'conference');
INSERT INTO jiveID (idType, id) VALUES (26, 1); INSERT INTO jiveID (idType, id) VALUES (26, 1);
/* update conference name/desc if there is a custom one set */ /* update conference name/desc if there is a custom one set */
UPDATE mucService SET mucService.subdomain = ( SELECT jiveProperty.propValue FROM jiveProperty WHERE jiveProperty.name = 'xmpp.muc.service' ) UPDATE mucService SET mucService.subdomain =
WHERE EXISTS ( SELECT jiveProperty.propValue FROM jiveProperty WHERE jiveProperty.name = 'xmpp.muc.service' ); ( SELECT CONVERT(NVARCHAR(255),jiveProperty.propValue) FROM jiveProperty WHERE jiveProperty.name = 'xmpp.muc.service' )
WHERE EXISTS
( SELECT CONVERT(NVARCHAR(255),jiveProperty.propValue) FROM jiveProperty WHERE jiveProperty.name = 'xmpp.muc.service' );
DELETE FROM jiveProperty WHERE name = 'xmpp.muc.service'; DELETE FROM jiveProperty WHERE name = 'xmpp.muc.service';
UPDATE mucService SET mucService.description = ( SELECT jiveProperty.propValue FROM jiveProperty WHERE jiveProperty.name = 'muc.service-name' ) UPDATE mucService SET mucService.description =
WHERE EXISTS ( SELECT jiveProperty.propValue FROM jiveProperty WHERE jiveProperty.name = 'muc.service-name' ); ( SELECT CONVERT(NVARCHAR(255),jiveProperty.propValue) FROM jiveProperty WHERE jiveProperty.name = 'muc.service-name' )
WHERE EXISTS
( SELECT CONVERT(NVARCHAR(255),jiveProperty.propValue) FROM jiveProperty WHERE jiveProperty.name = 'muc.service-name' );
DELETE FROM jiveProperty WHERE name = 'muc.service-name'; DELETE FROM jiveProperty WHERE name = 'muc.service-name';
/* transfer all system properties to muc specific properties */ /* transfer all system properties to muc specific properties */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment