Last modified: 2008-01-11 20:56:47 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 12584 - Don't update categorylinks.cl_timestamp when moving page
Don't update categorylinks.cl_timestamp when moving page
Product: MediaWiki
Classification: Unclassified
Database (Other open bugs)
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
Depends on:
  Show dependency treegraph
Reported: 2008-01-11 17:26 UTC by Zachary Hauri
Modified: 2008-01-11 20:56 UTC (History)
0 users

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

A patch to update the DB query (636 bytes, patch)
2008-01-11 18:07 UTC, Zachary Hauri

Description Zachary Hauri 2008-01-11 17:26:34 UTC
When pages are moved, it updates the time stamp on the categorylinks table. Since the category is already added to the page, it should keep the time stamp from when the category was added, not when the page was updated. (By the way, in case you didn't know already, the cl_timestamp provides the "publish date" on the various DynamicPageLists on Wikinews)

Currently, when the category is sorted by a sortkey that is NOT EQUAL to the page's title (or no sortkey is specified in the wikicode, which sorts it by the page's title), it does not update the cl_timestamp value.. so a workaround would be to explicitly specify sorting by something other than the page's title (trim off the last character of the title, random characters, whatever). For example:

Moving a page with [[Category:Foobar|Foobar]] updates cl_timestamp
Moving a page with [[Category:Foobar|Foobaz]] does NOT update cl_timestamp
Moving a page with [[Category:Foobar]] updates cl_timestamp
Moving a page with [[Category:Foobar|]] does NOT update cl_timestamp (Foobar becomes the sort key)
Moving a page with [[Category:Foobar|Foobar.]] does NOT update cl_timestamp

On line 2358 of includes/Title.php, modifying the SQL to set "cl_timestamp=cl_timestamp" will make it not update the timestamp.
Comment 1 Zachary Hauri 2008-01-11 17:37:49 UTC
I must make a correction: Moving a page with [[Category:Foobar|]] DOES update cl_timestamp.
Comment 2 Zachary Hauri 2008-01-11 18:07:16 UTC
Created attachment 4530 [details]
A patch to update the DB query

All this does is add ", cl_timestamp=cl_timestamp" to the query that updates categorylinks on page moves, which causes it to keep the same cl_timestamp
Comment 3 Brion Vibber 2008-01-11 20:56:47 UTC
Done in r29615; I cleaned up the query to use the modern system and added some notes in the comment.

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