Project

General

Profile

1
SELECT util.search_path_append('util');
2

    
3
-- runtime: 25 s ("real 0m21.770s")
4
SELECT set_col_types(:table_str, ARRAY[
5
  ('decimallatitude', 'double precision')
6
, ('decimallongitude', 'double precision')
7
]::col_cast[]);
8

    
9
ALTER TABLE :table ALTER COLUMN decimallatitude SET NOT NULL;
10
ALTER TABLE :table ALTER COLUMN decimallongitude SET NOT NULL;
11

    
12
-- runtime: 55 s ("real 0m53.677s")
13
SELECT create_if_not_exists($$CREATE INDEX geoscrub_output_input ON geoscrub_output (decimallatitude, decimallongitude, country, stateprovince, county)$$);
(6-6/7)