How to specify tables from two different databases (wikidatawiki_p and commonswiki_p)?
Topic on Talk:Quarry/Flow
I tried
- SELECT * FROM `commonswiki_p`.`pages` LIMIT 1
- USE DATABASE commonswiki_p
- USE commonswiki_p;
to override what's specified in the GUI.
It's not possible since around 2021. See Topic:W6tzj276xib56phf.
They are completely separate DB servers, you cannot make queries across multiple servers in the same query.
Apparently it was possible (see sample in the topic referenced by Matej) but then un-featured.
I found an easier solution, as the gap between Wikidata and Commons is only partial: one table at Commons is updated ( wbc_entity_usage), but not the other (page_props): quarry:query/86040
"Apparently it was possible " Yes, until the infrastructure ran into scaling problems.
Are there any measure in place to keep the databases in sync? The gap mentioned above is minor in percentages (maybe 0.1%), but in absolute numbers 4600 is a lot.