Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Wikipedia: Mediawiki

Moving a namespace

 

 

Wikipedia mediawiki RSS feed   Index | Next | Previous | View Threaded


jbezos at fundeu

Sep 28, 2009, 3:55 AM

Post #1 of 4 (428 views)
Permalink
Moving a namespace

Hello again,

How can I move a namespace to a new index? All I want
is to change the index from 106 to 112, so that articles
in this namespace are still found correctly.

Thanx
Javier

_______________________________________________
MediaWiki-l mailing list
MediaWiki-l [at] lists
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l


tor at wikia-inc

Sep 28, 2009, 4:27 AM

Post #2 of 4 (392 views)
Permalink
Re: Moving a namespace [In reply to]

On Monday, September 28, 2009, Javier Bezos <jbezos [at] fundeu> wrote:
> Hello again,
>
> How can I move a namespace to a new index? All I want
> is to change the index from 106 to 112, so that articles
> in this namespace are still found correctly.

Off the top of my head, the fastest way would be doing the following
query on the database:

update page set page_namespace = 112 where page_namespace = 106;

and then adjusting $wgExtraNamespaces

Remember to repeat this operation for the talk namespace.

--
Lucas 'TOR' Garczewski
Wikia Tech Team

_______________________________________________
MediaWiki-l mailing list
MediaWiki-l [at] lists
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l


daniel at brightbyte

Sep 28, 2009, 5:57 AM

Post #3 of 4 (392 views)
Permalink
Re: Moving a namespace [In reply to]

Ɓukasz Garczewski schrieb:
> On Monday, September 28, 2009, Javier Bezos <jbezos [at] fundeu> wrote:
>> Hello again,
>>
>> How can I move a namespace to a new index? All I want
>> is to change the index from 106 to 112, so that articles
>> in this namespace are still found correctly.
>
> Off the top of my head, the fastest way would be doing the following
> query on the database:
>
> update page set page_namespace = 112 where page_namespace = 106;
>
> and then adjusting $wgExtraNamespaces
>
> Remember to repeat this operation for the talk namespace.
>

If you do that, you have to update all secondary tables too: links, logs, etc.

running maintenance/rebuildall.php should help, but i don't know if it will fix
the log entries.

-- daniel

_______________________________________________
MediaWiki-l mailing list
MediaWiki-l [at] lists
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l


jbezos at fundeu

Sep 30, 2009, 12:20 AM

Post #4 of 4 (378 views)
Permalink
Re: Moving a namespace [In reply to]

> > update page set page_namespace = 112 where page_namespace = 106;
> >
> > and then adjusting $wgExtraNamespaces

>
> If you do that, you have to update all secondary tables too: links,
> logs, etc.

Thank you. As I expected it's not direct :-(. Fortunately,
the namespace is closed (no edits allowed) and its contents
come from a database, so I presume changing just the page
table won't hurt.

Javier


_______________________________________________
MediaWiki-l mailing list
MediaWiki-l [at] lists
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l

Wikipedia mediawiki RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.