I'm sorry, I didn't mean to criticize. What I was trying to do is to validate that list=backlinks and prop=categories are querying for the same relationship if the backlinks namespace is set for categories, using blnamespace=14. If they were two ways to query for the same relationship between pages, then the results should be the same, but they are not.
I've been able to verify that prop=categories returns the correct relationship, because the inverse (list=categorymembers) returns the inverse result. If prop=categories indicates that A is a parent of B, then list=categorymembers correctly indicates that B is a child of A. So what I'm trying to do is find the same relationship for portal pages (namespace=100). list=categorymembers also correctly returns the children who are portals, but I don't know how to find the parents that are portals. Thanks in advance, Robert -----Original Message----- From: Andre Engels [mailto:andreeng...@gmail.com] Sent: Sunday, March 20, 2011 10:15 AM To: Robert Crowe Cc: MediaWiki API announcements & discussion Subject: Re: [Mediawiki-api] Portals vs categories On Sun, Mar 20, 2011 at 5:43 PM, Robert Crowe <rob...@ourwebhome.com> wrote: > Thanks André, but after testing it seems that backlinks returns something > else. For example this query: > > http://en.wikipedia.org/w/api.php?action=query&titles=Category:Voltaire&prop=categories > > Returns: > > <query> > <pages> > <page pageid="3465227" ns="14" title="Category:Voltaire"> > <categories> > <cl ns="14" title="Category:Categories named after French people" /> > <cl ns="14" title="Category:Categories named after philosophers" /> > <cl ns="14" title="Category:Categories named after writers" /> > </categories> > </page> > </pages> > </query> > > But this query: > > http://en.wikipedia.org/w/api.php?action=query&list=backlinks&bltitle=Category:Voltaire&blnamespace=14&bllimit=500 > > Returns: > > <query> > <backlinks /> > </query> > > If I just use "Voltaire" instead of "Category:Voltaire" then I think it's > looking at a different page, right? The results are different, and don't > match the first query results: > > <query> > <backlinks> > <bl pageid="3465227" ns="14" title="Category:Voltaire" /> > <bl pageid="15582893" ns="14" title="Category:Novels by Voltaire" /> > </backlinks> > </query> You criticize my request because another request does not give the same result as a third request... I understand less and less of what you are trying to do. -- André Engels, andreeng...@gmail.com _______________________________________________ Mediawiki-api mailing list Mediawiki-api@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-api