Last modified: 2008-01-11 20:56:47 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 T14584, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 12584 - Don't update categorylinks.cl_timestamp when moving page
Don't update categorylinks.cl_timestamp when moving page
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Database (Other open bugs)
1.12.x
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  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: ---


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

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.


Navigation
Links