11. Given a database table named “animal” with four columns, please find out a CORRECT SQL command that can obtain the desired output as below.

(A) SELECT category, count(animalid) as countaid FROM animal WHERE born > '2023-02- 14' AND count(animalid)>=2 GROUP BY category ORDER BY count(animalid) DESC, category ASC
(B) SELECT category, count(animalid) as countaid FROM animal WHERE born > '2023-02- 14' GROUP BY category HAVING count(animalid)>=2 ORDER BY count(animalid) DESC, category ASC
(C) SELECT category, count(animalid) as countaid FROM animal GROUP BY category HAVING count(animalid)>=2 AND born > '2023-02-14' ORDER BY count(animalid), category DESC
(D) SELECT category, count(animalid) as countaid FROM animal WHERE count(animalid)>=2 GROUP BY category HAVING born > '2023-02-14' ORDER BY count(animalid) DESC, category ASC
(E) SELECT category, count(animalid) as countaid FROM animal WHERE born > '2023-02- 14' GROUP BY category ORDER BY count(animalid) DESC, category ASC

答案:登入後查看
統計: A(0), B(4), C(2), D(0), E(0) #3228169

詳解 (共 1 筆)

#6967382
1. 題目解析 這道題目要求我們從一個...
(共 1018 字,隱藏中)
前往觀看
0
0