[Wikipedia-l] Plans for RecentChanges page; programmers only!

Jan Hidders hidders at uia.ua.ac.be
Fri Feb 8 18:48:10 UTC 2002


From: "Brion L. VIBBER" <brion at pobox.com>
> Jan Hidders wrote:
>
> >Dear fellow programmers,
> >
> >I saw that the SQL code for the Recent Changes page is rather inefficient
> >and causes a lot of database access, so I decided to improve this.
However,
> >I can only do this properly if the timestamp field in the tables is split
in
> >a day and a time field.
> >
> Can I ask how exactly that would help? I'm not much of a database guru,
> so the answer isn't obvious to me and I'm a bit curious.

It allows me to do a GROUP BY on the day. That way I can take a left outer
join between the cur table and the old table and group on the combination of
cur_day and cur_title. This allows me to get all the information I need for
the page in one SQL statement.

-- Jan Hidders





More information about the Wikipedia-l mailing list