From 6d9aa68e0ee1a0ffc21a7ce2c1c4bb198e77615d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20Nicolaysen=20S=C3=B8rnes?= Date: Sun, 2 Dec 2007 19:38:17 +0100 Subject: [PATCH] appData: Some cleanup in SQL code --- include/appData.php | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/include/appData.php b/include/appData.php index ac1f1f4..8265763 100644 --- a/include/appData.php +++ b/include/appData.php @@ -214,7 +214,6 @@ class appData $sQueued = "false"; $sSelectType = ""; - $sLimit = ""; if(($sQueued == "true" || $sQueued == "all") && !$_SESSION['current']->hasPriv("admin")) @@ -280,17 +279,13 @@ class appData $sSelectType = " AND type = '?'"; $sQuery = "(SELECT COUNT(DISTINCT appData.id) as count FROM appData, - appFamily, appVersion WHERE - appFamily.appId = appVersion.appId - AND + appFamily WHERE ( appData.appId = appFamily.appId AND appData.versionId = '0' ) AND - appVersion.queued = 'false' - AND appFamily.queued = 'false'$sAppDataQueued$sSelectType) UNION ( SELECT COUNT(DISTINCT appData.id) as count FROM appData, @@ -407,17 +402,13 @@ class appData $sQuery = "( SELECT DISTINCT appData.* FROM appData, - appFamily, appVersion WHERE - appFamily.appId = appVersion.appId - AND + appFamily WHERE ( appData.appId = appFamily.appId AND appData.versionId = '0' ) AND - appVersion.queued = 'false' - AND appFamily.queued = 'false' AND appData.queued = '?'