Temos pavadinimas: WordPress, Shopify ir PHPFusion programuotojų bendruomenė :: Nesigauna užkl su where

Parašė Narysx· 2009 Bal. 3 16:04:20
#6

chipass parašė:
tu geriau pasakyk ka ir iskeliu duombaziu nori istraukt nes cia tavo tos uzklauso tai dieve apsaugok :)
ir siaip bandyk uzmest dar () apskliaudziant visus OR

$query = dbquery("SELECT games.te_id, AVG( score ) AS pts, te_name, te_city
FROM (
SELECT ga_home_id AS te_id, ga_home_score AS score FROM prefix_games
UNION
SELECT ga_away_id AS te_id, ga_away_score AS score FROM prefix_games) AS games,
prefix_teams WHERE (te_division='0' OR te_division='1' OR te_division='2')
AND (games.te_id = prefix_teams.te_id)
GROUP BY te_id
ORDER BY pts DESC");
:s


Suveikė. :) Ačiū.