What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 131 Stack Exchange communities.

Often you want to query some statistic for a user across all sites. For example, you might write a query to find your rejected suggested edits across all Stack Exchange sites.

To implement this, you would join on the network-wide user ID, across the tables corresponding to all the sites. (Doing it "properly" probably requires adding this as a column to each user table.)

Currently, it's possible to do this with a hack, by introspecting the system tables to see what sites exist, and using the output to write a query that joins across all the sites' tables. See:

But this is hard to use and cumbersome. Furthermore, this makes it difficult to bookmark and share queries because the second query has to be manually updated each time a new site is added to the Data Explorer.

Please add support for doing these joins automatically. Ideally, it would allow arbitrary joins, but even supporting only joining on global ID will make a common use case easier.

share|improve this question
    
Unless network account IDs were added the Users tables, I'm not sure I see much benefit in actually joining across sites - can you provide an example? Also, how would you see Data Explorer doing joins for you automatically, when it doesn't know the join criteria? –  Tim Stone Sep 25 '12 at 13:01
    
@TimStone: Added example. You would be joining on the network-wide ID. –  Mechanical snail Sep 26 '12 at 1:39
1  
"you might write a query to find your rejected suggested edits across all Stack Exchange site" - Hmm, would you actually want to join in this case, or simply run the same query against all of the sites simultaneously and union the results? Data Explorer does allow you to execute queries across all sites (in a non-manual way), but this is currently disabled on the public instance. –  Tim Stone Sep 26 '12 at 1:43

You must log in to answer this question.

Browse other questions tagged .