討論串[問題] mysql count/count 怎麼做??
共 2 篇文章
首頁
上一頁
1
下一頁
尾頁

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者tref (MFDA)時間19年前 (2006/11/10 22:26), 編輯資訊
0
0
0
內容預覽:
竟然沒人回,那就讓在下賺點p幣好了(賭光光..> <). 你要的結果,用個sql應該就可以解決. select t1.a,round(t2.cc/count(t1.b)*100,0) from A t1. inner join. (select a, count(b) as cc from A wh

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者cy0824 (chuchutrainz)時間19年前 (2006/11/10 05:01), 編輯資訊
0
0
0
內容預覽:
請問一下,我有兩個queries. Table:A. field:a,b,c. $query1= "SELECT a, count(b) from A where a='$a' group by a";. $query2= "select a, count(b) from A where a='$a
首頁
上一頁
1
下一頁
尾頁