6 Commits
1.1.4 ... 1.1.5

Author SHA1 Message Date
Mario de Frutos
cbe7b6dd15 Merge pull request #225 from CartoDB/develop
Release 1.1.5
2016-11-29 17:58:08 +01:00
Mario de Frutos
603d26c674 Version 1.1.5 artifacts 2016-11-29 17:43:28 +01:00
Mario de Frutos
355f6281e5 Merge pull request #224 from CartoDB/release-v-1.1.5
Release v 1.1.5
2016-11-29 17:40:53 +01:00
John Krauss
70f4807139 update NEWS 2016-11-29 16:45:10 +00:00
john krauss
84794124fd Merge pull request #223 from CartoDB/fix-getmeasure-exc-out-of-bounds
return NULL when there is no data for a measure at a geometry according to raster
2016-11-29 11:35:19 -05:00
John Krauss
6c08681446 return NULL when there is no data for a measure at a geometry according to our raster. Fixes #220 2016-11-29 16:41:44 +00:00
7 changed files with 2635 additions and 6 deletions

View File

@@ -1,3 +1,10 @@
1.1.5 (2016-11-29)
__Bugfixes__
* Return `NULL` instead of raising an exception when a measure is requested for
a geometry where it does not exist ([#220](https://github.com/CartoDB/observatory-extension/issues/220)).
1.1.4 (2016-11-21)
__Bugfixes__

File diff suppressed because one or more lines are too long

View File

@@ -1,5 +1,5 @@
comment = 'CartoDB Observatory backend extension'
default_version = '1.1.4'
default_version = '1.1.5'
requires = 'postgis, postgres_fdw'
superuser = true
schema = cdb_observatory

View File

@@ -1,5 +1,5 @@
comment = 'CartoDB Observatory backend extension'
default_version = '1.1.4'
default_version = '1.1.5'
requires = 'postgis, postgres_fdw'
superuser = true
schema = cdb_observatory

View File

@@ -410,7 +410,12 @@ BEGIN
ELSE geom
END;
raise notice 'Using boundary %', geom_id;
IF geom_id IS NULL THEN
RAISE NOTICE 'No boundary found for geom';
RETURN NULL;
ELSE
RAISE NOTICE 'Using boundary %', geom_id;
END IF;
IF normalize ILIKE 'area' AND numer_aggregate ILIKE 'sum' THEN
map_type := 'areaNormalized';

View File

@@ -66,7 +66,10 @@ t
obs_getmeasure_bad_geometry
t
(1 row)
obs_getmeasure_null
obs_getmeasure_null_geometry
t
(1 row)
obs_getmeasure_out_of_bounds_geometry
t
(1 row)
obs_getcategory_point

View File

@@ -203,10 +203,15 @@ SELECT abs(cdb_observatory.OBS_GetMeasure(
cdb_observatory._ProblemTestArea(),
'us.census.acs.B01003001') - 96230.2929825897) / 96230.2929825897 < 0.001 As OBS_GetMeasure_bad_geometry;
-- OBS_GetMeasure with NULL Input
-- OBS_GetMeasure with NULL Input geometry
SELECT cdb_observatory.OBS_GetMeasure(
NULL,
'us.census.acs.B01003001') IS NULL As OBS_GetMeasure_null;
'us.census.acs.B01003001') IS NULL As OBS_GetMeasure_null_geometry;
-- OBS_GetMeasure where there is no data
SELECT cdb_observatory.OBS_GetMeasure(
ST_SetSRID(st_point(0, 0), 4326),
'us.census.acs.B01003001') IS NULL As OBS_GetMeasure_out_of_bounds_geometry;
-- Point-based OBS_GetCategory
SELECT cdb_observatory.OBS_GetCategory(