Last modified: 2014-01-03 15:35:13 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T61286, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 59286 - DBQ-30 List of templates used only in the user namespace
DBQ-30 List of templates used only in the user namespace
Status: RESOLVED FIXED
Product: Tool Labs tools
Classification: Unclassified
Database Queries (Other open bugs)
unspecified
All All
: Unprioritized minor
: ---
Assigned To: Bugzilla Bug Importer (valhallasw)
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-01-03 15:34 UTC by Bugzilla Bug Importer (valhallasw)
Modified: 2014-01-03 15:35 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Bugzilla Bug Importer (valhallasw) 2014-01-03 15:34:55 UTC
This issue was converted from https://jira.toolserver.org/browse/DBQ-30.
Summary: List of templates used only in the user namespace
Issue type: Task - A task that needs to be done.
Priority: Minor
Status: Done
Assignee: (none)

-------------------------------------------------------------------------------
From: Thetrick <hetrickt@yahoo.com>
Date: Sun, 29 Jun 2008 15:38:57
-------------------------------------------------------------------------------

A list of templates transcluded only in the user namespace (not links). This is in order to identify personal templates (navboxes, page headers, etc.) residing in the template namespace. Formatting should be as [[Template:templatenamehere]] in a text file, just like DBQ28. Thanks.
Comment 1 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:34:57 UTC
-------------------------------------------------------------------------------
From: DaB. <dab@ts.wikimedia.org>
Date: Sun, 29 Jun 2008 15:52:33
-------------------------------------------------------------------------------

for enwp?
Comment 2 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:34:58 UTC
-------------------------------------------------------------------------------
From: Thetrick <hetrickt@yahoo.com>
Date: Sun, 29 Jun 2008 16:04:50
-------------------------------------------------------------------------------

Yes, en.wikipedia.org. Apologies for not being specific.

Also, as with DBQ28, how can I get this re-run in a few weeks: ask here, or open a new task?

And to further revise and extend, by "user namespace" I mean both the user and user_talk namespaces (2 and 3, I believe).
Comment 3 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:00 UTC
-------------------------------------------------------------------------------
From: Thetrick <hetrickt@yahoo.com>
Date: Mon, 07 Jul 2008 16:45:23
-------------------------------------------------------------------------------

Greetings. Is this being worked at all? Thanks.
Comment 4 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:01 UTC
-------------------------------------------------------------------------------
From: Thetrick <hetrickt@yahoo.com>
Date: Thu, 10 Jul 2008 21:58:06
-------------------------------------------------------------------------------

Hello?
Comment 5 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:03 UTC
-------------------------------------------------------------------------------
From: Misza <misza1313@gmail.com>
Date: Sun, 13 Jul 2008 11:42:20
-------------------------------------------------------------------------------

This strikes me as something that won't work as you expect.

For example, most Wikipedia templates are listed (as in, transcluded as an example) somewhere on http://en.wikipedia.org/wiki/Wikipedia:Template_messages - that would be one hell lot of exclusions to hardcode in the query.

There can also be other uses - see http://en.wikipedia.org/wiki/Special:WhatLinksHere/Template:Userpage (a typically userspace-only template) and browse through different namespaces to see how often the algorithm fails (there's even one article space use on http://en.wikipedia.org/wiki/Editor:Gangsta36t because someone confused the userspace name).

Please confirm that this is indeed what you want (for example, Template:Userpage would **not** be listed in the result).
Comment 6 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:05 UTC
-------------------------------------------------------------------------------
From: SQL <sxwiki@gmail.com>
Date: Wed, 13 Aug 2008 18:00:30
-------------------------------------------------------------------------------

Done, see http://toolserver.org/~sql/DBQ/30.txt.gz

I agree with the above, however, that you might not find this the most useful thing.

Query is at http://toolserver.org/~sql/DBQ/30.sql if anyone needs to rerun it. Takes about half an hour on enwiki_p.
Comment 7 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:06 UTC
-------------------------------------------------------------------------------
From: MZMcBride <mzmcbride@gmail.com>
Date: Fri, 15 Aug 2008 19:30:17
-------------------------------------------------------------------------------

The list generated includes templates like http://en.wikipedia.org/wiki/Template:! and http://en.wikipedia.org/wiki/Template:Ambox

Clearly something's borked.
Comment 8 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:08 UTC
-------------------------------------------------------------------------------
From: SQL <sxwiki@gmail.com>
Date: Fri, 15 Aug 2008 19:46:08
-------------------------------------------------------------------------------

Interesting, I wonder where I went wrong.
Comment 9 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:09 UTC
-------------------------------------------------------------------------------
From: CBM <cbm.wikipedia@gmail.com>
Date: Fri, 15 Aug 2008 22:11:25
-------------------------------------------------------------------------------

What went wrong is that the page_namespace in the final subquery was already limited to equal 2 earlier on, so the subquery can never return any rows.

Here's a query that should generate more useful data:

select concat('[[Template:',t_title,']] ', page_is_redirect)  
from (select distinct tl_title as t_title from templatelinks  
where tl_namespace = 10) as temp  
join page on page_namespace = 10 and page_title = temp.t_title  
where not exists  
(select 1 from page join templatelinks  
on page_id = tl_from and tl_namespace = 10  
where tl_title = t_title and page_namespace != 2 );

I put the results at http://toolserver.org/~cbm/data/DBQ-30.txt
Comment 10 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:11 UTC
-------------------------------------------------------------------------------
From: SQL <sxwiki@gmail.com>
Date: Sat, 16 Aug 2008 04:55:25
-------------------------------------------------------------------------------

Appears to have gotten it, thank you CBM ![][1]

   [1]: https://jira.toolserver.org/images/icons/emoticons/smile.gif
Comment 11 Bugzilla Bug Importer (valhallasw) 2014-01-03 15:35:13 UTC
This bug was imported as RESOLVED. The original assignee has therefore not been
set, and the original reporters/responders have not been added as CC, to
prevent bugspam.

If you re-open this bug, please consider adding these people to the CC list:
Original assignee: (none)
CC list: cbm.wikipedia@gmail.com, b@mzmcbride.com, wikimedia-bugzilla@dabpunkt.eu, misza@misza.net, sxwiki@gmail.com

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links