Last modified: 2014-01-03 16:08: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 T61442, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 59442 - DBQ-171 Bug In wachlist Query
DBQ-171 Bug In wachlist Query
Status: RESOLVED FIXED
Product: Tool Labs tools
Classification: Unclassified
Database Queries (Other open bugs)
unspecified
All All
: Unprioritized major
: ---
Assigned To: Bugzilla Bug Importer (valhallasw)
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-01-03 16:08 UTC by Bugzilla Bug Importer (valhallasw)
Modified: 2014-01-03 16:08 UTC (History)
0 users

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


Attachments

Description Bugzilla Bug Importer (valhallasw) 2014-01-03 16:08:01 UTC
This issue was converted from https://jira.toolserver.org/browse/DBQ-171.
Summary: Bug In wachlist Query
Issue type: Task - A task that needs to be done.
Priority: Major
Status: Done
Assignee: Hoo man <hoo@online.de>

-------------------------------------------------------------------------------
From: reza <reza.energy@gmail.com>
Date: Thu, 08 Dec 2011 00:06:27
-------------------------------------------------------------------------------

I wanted to list fa.wiki notifications and I used these queries and I had different answers.
    
    SELECT Wl_title,Count(Wl_title),ts_wl_user_touched_cropped  FROM watchlist JOIN page ON page_title=Wl_title WHERE page_len>0 AND page_is_redirect=0 and Wl_namespace=0 GROUP BY Wl_title ORDER BY count(Wl_title) DESC LIMIT 20;
    
    SELECT Wl_title,Count(Wl_title) FROM watchlist JOIN page ON page_title=Wl_title WHERE page_len>0 AND page_is_redirect=0 and Wl_namespace=0 GROUP BY Wl_title ORDER BY count(Wl_title) DESC LIMIT 20;

all of the Count numbers are different!

also according to   
http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/maintenance/tables.sql?view=markup  
and  
http://www.mediawiki.org/wiki/Manual:Watchlist_table  
it have wl_user and wl_notificationtimestamp Fields but with describe command it shows ts_wl_user_touched_cropped !  
also none of my result are not equal with (page count)  
http://toolserver.org/~mzmcbride/watcher/?db=fawiki_p
Comment 1 Bugzilla Bug Importer (valhallasw) 2014-01-03 16:08:03 UTC
-------------------------------------------------------------------------------
From: reza <reza.energy@gmail.com>
Date: Thu, 08 Dec 2011 00:12:52
-------------------------------------------------------------------------------

also for
    
    SELECT Wl_title,Count(Wl_title) FROM watchlist JOIN page ON page_title=Wl_title WHERE page_title="فرح_پهلوی" AND Wl_namespace=0 AND page_len>0 GROUP BY Wl_title;

and http://toolserver.org/~mzmcbride/watcher/?db=fawiki_p&titles=%D9%81%D8%B1%D8%AD_%D9%BE%D9%87%D9%84%D9%88%DB%8C

has different answers
Comment 2 Bugzilla Bug Importer (valhallasw) 2014-01-03 16:08:04 UTC
-------------------------------------------------------------------------------
From: Hoo man <hoo@online.de>
Date: Thu, 08 Dec 2011 22:46:24
-------------------------------------------------------------------------------

In the query within the comment you forgot AND page_namespace=0  
So the right query is:
    
    SELECT Wl_title,Count(Wl_title) FROM watchlist JOIN page ON page_title=Wl_title WHERE page_title="فرح_پهلوی" AND Wl_namespace=0 AND page_len>0 AND page_namespace=0 GROUP BY Wl_title;

Which should be equal to
    
    SELECT Wl_title,Count(Wl_title) FROM watchlist WHERE wl_title = 'فرح_پهلوی' AND wl_namespace = 0;

I think you did the same mistake in the queries within the description, but I don't have enough time to test that atm... It would be fine, if you could tell, if it's the solution.
Comment 3 Bugzilla Bug Importer (valhallasw) 2014-01-03 16:08:06 UTC
-------------------------------------------------------------------------------
From: reza <reza.energy@gmail.com>
Date: Thu, 08 Dec 2011 23:15:35
-------------------------------------------------------------------------------

thank you now it is correct but why Fields are not the same as help and trunk?
Comment 4 Bugzilla Bug Importer (valhallasw) 2014-01-03 16:08:08 UTC
-------------------------------------------------------------------------------
From: Hoo man <hoo@online.de>
Date: Thu, 08 Dec 2011 23:21:34
-------------------------------------------------------------------------------

Great ![][1]

The toolserver tables don't include all information the "real" databases do, mostly because of privacy reasons. So in the given example the timestamp is cropped so that only year, month and day can be seen.

   [1]: https://jira.toolserver.org/images/icons/emoticons/smile.gif
Comment 5 Bugzilla Bug Importer (valhallasw) 2014-01-03 16:08:09 UTC
-------------------------------------------------------------------------------
From: DaB. <dab@ts.wikimedia.org>
Date: Thu, 08 Dec 2011 23:27:12
-------------------------------------------------------------------------------

Please notice that ts_wl_user_touched_cropped is not a cropped wl_notificationtimestamp, but a cropped user_touched (the watchlist-table is joined with the user-table for that view).
Comment 6 Bugzilla Bug Importer (valhallasw) 2014-01-03 16:08:11 UTC
-------------------------------------------------------------------------------
From: reza <reza.energy@gmail.com>
Date: Thu, 08 Dec 2011 23:58:20
-------------------------------------------------------------------------------

Thank you
Comment 7 Bugzilla Bug Importer (valhallasw) 2014-01-03 16:08: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: hoo@online.de
CC list: reza.energy@gmail.com, hoo@online.de, wikimedia-bugzilla@dabpunkt.eu

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


Navigation
Links