Index: branches/5.2.x/core/install/upgrades.sql
===================================================================
diff -u -r15235 -r15246
--- branches/5.2.x/core/install/upgrades.sql	(.../upgrades.sql)	(revision 15235)
+++ branches/5.2.x/core/install/upgrades.sql	(.../upgrades.sql)	(revision 15246)
@@ -2689,3 +2689,23 @@
 INSERT INTO Permissions VALUES (DEFAULT, 'in-portal:item_filters.add', 11, 1, 1, 0);
 INSERT INTO Permissions VALUES (DEFAULT, 'in-portal:item_filters.edit', 11, 1, 1, 0);
 INSERT INTO Permissions VALUES (DEFAULT, 'in-portal:item_filters.delete', 11, 1, 1, 0);
+
+ALTER TABLE SlowSqlCapture CHANGE QueryCrc QueryCrc BIGINT(11) NOT NULL DEFAULT '0';
+UPDATE SlowSqlCapture
+SET QueryCrc = CAST((QueryCrc & 0xFFFFFFFF) AS UNSIGNED INTEGER)
+WHERE QueryCrc < 0;
+
+ALTER TABLE ImportCache CHANGE VarName VarName BIGINT(11) NOT NULL DEFAULT '0';
+UPDATE ImportCache
+SET VarName = CAST((VarName & 0xFFFFFFFF) AS UNSIGNED INTEGER)
+WHERE VarName < 0;
+
+ALTER TABLE PageContent CHANGE ContentNum ContentNum BIGINT(11) NOT NULL DEFAULT '0';
+UPDATE PageContent
+SET ContentNum = CAST((ContentNum & 0xFFFFFFFF) AS UNSIGNED INTEGER)
+WHERE ContentNum < 0;
+
+ALTER TABLE CachedUrls CHANGE Hash Hash BIGINT(11) NOT NULL DEFAULT '0';
+UPDATE CachedUrls
+SET Hash = CAST((Hash & 0xFFFFFFFF) AS UNSIGNED INTEGER)
+WHERE Hash < 0;
