From 3218d693e436fe6d2a5975ccdeb469fb41d2bd66 Mon Sep 17 00:00:00 2001 From: Ryan Voots Date: Thu, 25 Feb 2010 21:53:47 -0500 Subject: [PATCH] fuck --- plugins/factoids.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/factoids.pm b/plugins/factoids.pm index 1826ba0..76d3424 100644 --- a/plugins/factoids.pm +++ b/plugins/factoids.pm @@ -503,7 +503,7 @@ sub _soundex_matches { #XXX HACK WARNING: not really a hack, but something to document, the inner query here seems to work fine on sqlite, but i suspect on other databases it might need an ORDER BY factoid_id clause to enforce that it picks the last entry in the database my $rows = $dbh->selectall_arrayref( - "SELECT * FROM (SELECT factoid_id,subject,predicate FROM factoid GROUP BY original_subject) as subquery WHERE NOT (predicate = ' ') AND soundex = ? LIMIT 10", + "SELECT * FROM (SELECT factoid_id,subject,predicate FROM factoid WHERE soundex = ? GROUP BY original_subject) as subquery WHERE NOT (predicate = ' ') LIMIT 10", undef, $soundex );