On Sat, Nov 16, 2002 at 02:35:01AM -0800, Jonathan Walther wrote:
On Sat, Nov 16, 2002 at 11:22:47AM +0100, Magnus Manske
wrote:
No, "broken links" are links to articles
that don't exist at all, not to
"blank" articles.
Correct. I am proposing that there should be no broken links because all
articles are created, even if only blank articles. Periodically a
process could sweep blank articles with nothing linking to them from the
database. For instance,
REMOVE FROM current_articles WHERE ...
Ok, here is what the SQL query would look like:
REMOVE FROM current_articles
WHERE
text=NULL
AND NOT
article_id IN
( SELECT destination FROM links DISTINCT );
You see? No need for a separate table of dangling links, if you make sure
that every article comes into existance. Subqueries are really nice.
Cheers!
<Location /wiki>
SetHandler mod-wikipedia
</Location>
Jonathan
--
Geek House Productions, Ltd.
Providing Unix & Internet Contracting and Consulting,
QA Testing, Technical Documentation, Systems Design & Implementation,
General Programming, E-commerce, Web & Mail Services since 1998
Phone: 604-435-1205
Email: djw(a)reactor-core.org
Webpage:
http://reactor-core.org
Address: 2459 E 41st Ave, Vancouver, BC V5R2W2