急,急,急pl sql,oracle根據查詢結果統計數量

時間 2021-07-23 15:07:50

1樓:

select calssno, 語文成績為a的條數=count(case when project='語文' and mark='a' then 1 end),數學成績為b的條數=count(case when project='數學' and mark='b' then 1 end),

英語成績為c的條數=count(case when project='英語' and mark='c' then 1 end)

from student_mart

group by calssno

2樓:匿名使用者

select a.calssno, a.count_1, b.count_2, c.count_3

from

(select count(*) as count_1, calssno

from student_mart

where project = '語文'

and mark = 'd'

group by calssno) a,

(select count(*) as count_2, calssno

from student_mart

where project = '數學'

and mark = 'd'

group by calssno) b,

(select count(*) as count_3, calssno

from student_mart

where project = '英語'

and mark = 'd'

group by calssno) c

where a.calssno = b.calssno

and b.calssno = c.calssno

3樓:小哥無爭

select count(*) from student_mart where mark='d' and project='語文'

union

select count(*) from student_mart where mark='d' and project='數學'

union

select count(*) from student_mart where mark='d' and project='英語'

4樓:匿名使用者

select project,count(*) from student_mart t where t.mark='d' group by t.project

oracle 如何查詢符合某個範圍內的所有資料的個數?急**等

5樓:

lz 好有愛。。。樓上的回答不滿足你嗎?按照你說的滿足了。。。

6樓:韓福潔

select count(*) tablename where psize between 150 and 200;

就是加個條件啊。。。。。

7樓:匿名使用者

select count(*) from tb where col between 150 and 200

??這個意思麼??

oracle pl/sql查詢結果如何自動換行

8樓:匿名使用者

|可以在sql語句中加換行符chr(10)實現,比如欄位a長度為150,sql可以這麼寫

select substr(t.a, 0, 100) ||版 char(10) ||substr(t.a, 101, len(t.a)) from table t

或者你也可權以將內容複製出來,放入一個自動換行的記事本,儲存之後就是換行後的結果,至於每行字元數量,你可以根據你的需要調整記事本視窗的寬度完成,但是一定要儲存之後才有效果

9樓:匿名使用者

在尾巴加上換行符啊 比如 select '2012'|| chr(10) from dual;

2根號3乘根號3 2根號6除根號3,急急急急急急急急急急急急急急

2根號3乘根號3 2根號6除根號3 2 3 6根號2 6 6根號2 x 1 x 2 1 x 2 x 2x 2 1 0 x 2 x 1 0 由一元二次方程解的公式有 x b b 2 4ac 2a 所以,x 1 1 2 4 1 2即,x 1 5 2 解 1 2 3 3 2 6 3 2 3 2 2 6 2...

急急急急急急急急急急急急急急急急急急急急震撼心靈的作文不要抄,寫的好的加分

阿瑟 所有的人都應該反思,社會何以變成現在這樣?是社會質變了,還是我們都麻木了?伸出你的手,希望有一天,只是希望,這種畫面不再出現!真的縴夫!那有幾多愛?天府的脊樑,我想,沒有什麼可以打動我了,除非涉及到我和我的家人。但是我錯了,當如此之多的 擺在面前的時候,那種強烈的的視覺衝擊和久違的震撼深深的打...

急急急急急急急急急急急急急急急急急急急急急急急急懇請各位大師替小弟算算,萬分感激

的觀點是我自己的愚見,我讀了喬葉 和自己的棋整理答案。1,因為作者認為,遊戲是為了證明自己,所謂的對手,但另一種解釋。運動員誰贏在奧運會上,面對自己真正的對手,他們的成就把握超越自己的結果,作者認為他們的勝利的結果不排在第一位,但和自己的殘酷的戰鬥之前採摘冠。br 2,因為知道如何下棋,和自己需要了...