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

Parašė Narysx· 2009 Bal. 2 22:04:25
#1

$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");




Kas blogai?

Redagavo Narysx· 2009 Bal. 2 22:04:28