-
Notifications
You must be signed in to change notification settings - Fork 0
/
mixed_use_pwb_summaries
89 lines (81 loc) · 2.74 KB
/
mixed_use_pwb_summaries
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
SELECT
city_id
#,parcel_is_locked_out
#,got_proposal_of_either_type
#,had_development_event
#rgc_id
#plan_type_id
,minimum_dwelling_units_per_acre
,maximum_dwelling_units_per_acre
,minimum_far
,maximum_far
#,zone
#,definition
#,max_du_acre_flu
#,max_far_flu
#residential_density_category
#,round(maximum_dwelling_units_per_acre/10,0) as du_per_acre_group
#,maximum_dwelling_units_per_acre
#,city_id
,count(run_104_20180406_2014.parcels_with_built_2014_2050.parcel_id) as parcels
,sum(parcel_sqft)/43560 as acres
,sum(net_2014_residential_unit_capacity) as net_du_capacity
,sum(net_2014_non_residential_sqft_capacity) as net_sqft_capacity
,sum(got_proposal_of_either_type) as parcels_w_proposal
,sum(got_proposal_of_either_type*parcel_sqft/43560) as acres_w_proposal
,sum(got_proposal_of_either_type*net_2014_residential_unit_capacity) as parcels_w_proposal_net14_du_capacity
,sum(got_proposal_of_either_type*net_2014_non_residential_sqft_capacity) as parcels_w_proposal_net14_sqft_capacity
,sum(had_development_event) as parcels_developed
,sum(had_development_event*parcel_sqft/43560) as acres_developed
,sum(had_development_event*hu_chg_14_50) as hu_chg_on_developed
,sum(had_development_event*hh_chg_14_50) as tot_hh_chg_on_developed
,sum(had_development_event*res_sqft_chg_14_50) as tot_res_sqft_chg_on_developed
,sum(had_development_event*nonres_sqft_chg_14_50) as tot_nonres_sqft_chg_on_developed
,sum(had_development_event*job_chg_14_50) as tot_job_chg_on_developed
,sum(had_development_event*per_chg_14_50) as tot_per_chg_on_developed
,sum(hu_chg_14_50) as tot_hu_chg
,sum(households_14) as hh_14
,sum(households_50) as hh_50
,sum(hh_chg_14_50) as tot_hh_chg
,sum(res_sqft_chg_14_50) as tot_res_sqft_chg
,sum(nonres_sqft_chg_14_50) as tot_nonres_sqft_chg
,sum(jobs_14) as jobs_14
,sum(jobs_50) as jobs_50
,sum(job_chg_14_50) as tot_job_chg
,sum(persons_14) as persons_14
,sum(persons_50) as persons_50
,sum(per_chg_14_50) as tot_per_chg
,sum(hu_14) as hu_14
,sum(hu_50) as hu_50
,sum(res_sqft_14) as res_sqft_14
,sum(res_sqft_50) as res_sqft_50
,sum(nonres_sqft_14) as nonres_sqft_14
,sum(nonres_sqft_50) as nonres_sqft_50
FROM run_104_20180406_2014.parcels_with_built_2014_2050
#inner join run_104_20180406_2014.seattle_select_mu_zoning_parcels
#on run_104_20180406_2014.parcels_with_built_2014_2050.parcel_id = run_104_20180406_2014.seattle_select_mu_zoning_parcels.parcel_id
where
is_mixed_use = 'yes'
#parcel_is_locked_out = 0
#and
#got_proposal_of_either_type = 0
#and
#had_development_event = 1
#and
#city_id = 53
#and
#zone_id in (3413,3414,3415)
#and
#got_proposal_of_either_type = 0
group by
#plan_type_id
city_id
#,minimum_dwelling_units_per_acre
#,maximum_dwelling_units_per_acre
#,minimum_far
#,maximum_far
#,city_id
#order by
#residential_density_category
#,du_per_acre_group
;