select * from (5 F4 \# d* S7 u6 b G9 y, F: b
select business_year x,round(cast(sum(recruit_student_count) as decimal(20,2))/1000,1) y ,'招生人数' as s ,area
# s' Z: ]' g4 _ J' z! f" sfrom admissions_data_info " J3 p5 ~! s- K5 [) {
group by business_year,area) \6 {1 [' [7 x, \( [' J A; }1 {
union all3 F) _+ z/ s: I$ e3 I; s, q2 X) F
select business_year x,round(cast(sum(school_age_number) as decimal(20,2))/1000,1) y ,'入学缺口' as s ,area
+ }) H; }3 i( F1 d" bfrom admissions_data_info
- z3 I8 }( Y, ?8 @8 Bgroup by business_year,area
! { Z& W5 h, S& L" V/ s q8 ~! tunion all: X) O r* D* E$ a* N
select business_year x,round(cast(sum(recruit_student_count) as decimal(20,2))/1000 ,1) y ,'招生人数' as s ,'所有区县' area
; K8 D3 K! _" r1 o3 _& [from admissions_data_info
# X/ {3 V1 C4 r: t0 lgroup by business_year- K# M3 C3 P! ]0 g
union all1 G2 Z$ l* L1 g" l
select business_year x,round(cast(sum(school_age_number) as decimal(20,2))/1000,1) y ,'入学缺口' as s ,'所有区县' area. A7 `! \- h7 }+ H! l- k
from admissions_data_info% C- o6 t# X, s! z7 g$ t
group by business_year
' U. k% W/ b, B9 P3 q)a* ]* @6 z* t- M$ b; J8 C( U" X
where area=:area
' N3 b! M9 q2 d/ A5 V3 p4 T" x5 Porder by x |