Merge "(bug 37755) Set robot meta tags for 'view source' pages"
[lhc/web/wiklou.git] / maintenance / archives / patch-user_properties.sql
index a58857d..85b0061 100644 (file)
@@ -1,8 +1,20 @@
--- Table for holding user properties.
-
+--
+-- User preferences and perhaps other fun stuff. :)
+-- Replaces the old user.user_options blob, with a couple nice properties:
+--
+-- 1) We only store non-default settings, so changes to the defauls
+--    are now reflected for everybody, not just new accounts.
+-- 2) We can more easily do bulk lookups, statistics, or modifications of
+--    saved options since it's a sane table structure.
+--
 CREATE TABLE /*_*/user_properties(
-  up_user bigint not null,
+  -- Foreign key to user.user_id
+  up_user int not null,
+
+  -- Name of the option being saved. This is indexed for bulk lookup.
   up_property varbinary(32) not null,
+
+  -- Property value as a string.
   up_value blob
 ) /*$wgDBTableOptions*/;