User:Faebot/thanks

From Meta, a Wikimedia project coordination wiki

Top ten thanks reports[edit]

Scope[edit]

This family of reports is a summary of the top ten users of thanks and the most thanked accounts on different Wikimedia projects. The database queries take a fairly long time to run, so this informal report is only updated once a month but retrospectively includes data from the start of 2014.

Please contact if you would like a project added to this report, or use Special:EmailUser/Faebot in confidence if you would like a courtesy opt-out for your account(s) from the reports.

Projects included[edit]

Wiki Link
Commons /commons
Meta /meta
English Wikipedia /en
French Wikipedia /fr
Arabic Wikipedia /ar
Russian Wikipedia /ru
Norwegian Wikipedia /no
Spanish Wikipedia /es
Portuguese Wikipedia /pt
Ukrainian Wikipedia /uk
Polish Wikipedia /pl
Esperanto Wikipedia /eo
Wikidata /wikidata
Outreach wiki /outreach

Links in red have been added to Faebot's programme, but may need to wait for a scheduled run of the report.

Folders automatic list[edit]


Query source code[edit]

To see a running example, refer to http://quarry.wmflabs.org/query/7218. As the log_action table can be extremely large, queries may take hours for some wikis, though others may completed in a minute or two. The variation is probably related to indexing, use of GROUP BY, and the relationship between number of editors and total number of logged actions they make.

The underpinning SQL used looks like:

Variables:
 {0} = wikiname
 {1} = month
 {2} = accounts to skip

SELECT log_user_text,
  COUNT(log_action)
  FROM {0}wiki_p.logging_userindex
WHERE log_action="thank"
  AND LEFT(log_timestamp,6)="{1}"
  AND log_user_text NOT IN {2}
GROUP BY log_user_text
ORDER BY COUNT(log_action) DESC
LIMIT 10;

See also[edit]