r2617 - fixed getRackRowInfo() to return correct data
authorDenis Ovsienko <infrastation@yandex.ru>
Wed, 8 Apr 2009 13:59:11 +0000 (13:59 +0000)
committerDenis Ovsienko <infrastation@yandex.ru>
Wed, 8 Apr 2009 13:59:11 +0000 (13:59 +0000)
inc/database.php

index 9c0ec9c131b391a65dc78e020095234bb53396e0..ab50389f1c633d11e151cb37a0d7e4e8dbeb7939 100644 (file)
@@ -60,7 +60,7 @@ function getRackRowInfo ($rackrow_id)
                "select RackRow.id as id, RackRow.name as name, count(Rack.id) as count, " .
                "if(isnull(sum(Rack.height)),0,sum(Rack.height)) as sum " .
                "from RackRow left join Rack on Rack.row_id = RackRow.id " .
-               " " .
+               "where RackRow.id = ${rackrow_id} " .
                "group by RackRow.id";
        $result = useSelectBlade ($query, __FUNCTION__);
        if ($row = $result->fetch (PDO::FETCH_ASSOC))