瀏覽代碼

Postgres requires all selected columns to be used in aggregate functions or specified in the GROUP BY clause

tags/last-sinatra-version
Adrian Short 14 年之前
父節點
當前提交
1a16273242
共有 1 個檔案被更改,包括 2 行新增2 行删除
  1. +2
    -2
      app.rb

+ 2
- 2
app.rb 查看文件

@@ -106,7 +106,7 @@ get '/bodies/:body/elections/:date' do

WHERE c.election_id = #{@election.id}

GROUP BY c.party_id
GROUP BY c.party_id, p.colour, p.name

ORDER BY seatz DESC, votez DESC
")
@@ -124,7 +124,7 @@ get '/bodies/:body/elections/:date' do
c.district_id = d.id
AND c.election_id = #{@election.id}

GROUP BY c.district_id
GROUP BY c.district_id, d.name, d.slug

ORDER BY d.name
")


Loading…
取消
儲存