SELECT * FROM ( SELECT page_title,count(cl_to) AS cnt FROM page,categorylinks WHERE page_id=cl_from AND cl_to in ( "Frau" , "Geboren_1901" , "Gestorben_1986" ) GROUP BY cl_from ) AS tbl1 WHERE tbl1.cnt = 3 ;
Mh, yeah, that is pretty much the same idea that my http://toolserver.org/~dschwen/intersection/ uses
Except that I'm using several queries into a temporary table instead of assembling one query with subqueries (plus it also supports link-intersection).
But, then again my too supports deep indexing, which _needs_ multiple queries. So I opted for flexibility here.
Task: On German Wikipedia (yay atomic categories!), find women who
Yeah this is all nice and fine, but we've discussed this issue ad nauseam:
* Atomic categories = _trivial_ intersection * Non-atomic categories = total bullshit that makes me vomit (sorry guys!)
I find it a little frustrating that this wheel gets reinvented so often. My tool was used a couple of times after I posted it, and now as maybe one user per day (from a quick glance at the logs). What is going on here? I'm stating to think tht nobody actually gives a damn about category intersection, except for a couple of vocal people on the mailing list. And out of these only a fraction actually _works_ on the problem.
So we have shown multiple times now that cat intersection is technically feasible. What we nee now is massive lobbying for atomic categorisation. THAT is the hurdle right now IMO. Not some SQL queries.