From: Andrew Dolgov Date: Fri, 6 Jan 2006 13:14:19 +0000 (+0100) Subject: fix search query (closes #30) X-Git-Tag: schema_freeze_for_1.1.2~13 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=8e84993bf96a7a53b56fa5c2b791a023f2877fb0;p=tt-rss.git fix search query (closes #30) --- diff --git a/backend.php b/backend.php index e0141d7c..2dba06ef 100644 --- a/backend.php +++ b/backend.php @@ -1114,8 +1114,8 @@ $search_mode = db_escape_string($_GET["smode"]); if ($search) { - $search_query_part = "(upper(title) LIKE upper('%$search%') - OR content LIKE '%$search%') AND"; + $search_query_part = "(upper(ttrss_entries.title) LIKE upper('%$search%') + OR ttrss_entries.content LIKE '%$search%') AND"; } else { $search_query_part = ""; } @@ -1147,7 +1147,7 @@ // override query strategy and enable feed display when searching globally if ($search && $search_mode == "All feeds") { - $query_strategy_part = "id > 0"; + $query_strategy_part = "ttrss_entries.id > 0"; $vfeed_query_part = "ttrss_feeds.title AS feed_title,"; } else if (sprintf("%d", $feed) == 0) { $query_strategy_part = "ttrss_entries.id > 0";