SELECT recentchanges.rc_user AS revs,
(CASE WHEN user_properties.up_value IN (1,'nostalgia') THEN 'nostalgia'
  WHEN user_properties.up_value IN (2,'cologneblue') THEN 'cologneblue'
  WHEN user_properties.up_value = 'myskin' THEN 'myskin'
  WHEN user_properties.up_value = 'simple' THEN 'simple'
  WHEN user_properties.up_value = 'standard' THEN 'standard'
  WHEN user_properties.up_value = 'modern' THEN 'modern'
  WHEN user_properties.up_value = 'monobook' THEN 'monobook'
  WHEN user_properties.up_value = 'chick' THEN 'chick'
  ELSE 'vector' END) AS skin
FROM recentchanges
   LEFT JOIN user_properties ON user_properties.up_user = recentchanges.rc_user
   WHERE user_properties.up_property = 'skin' AND recentchanges.rc_namespace = 0 AND recentchanges.rc_type < 2
   GROUP BY revs
   HAVING revs >= 5;