Skip to content

Commit ba36ce8

Browse files
Merge pull request #345 from 3DBAG/webservices-attributes-fix
fixing tiles table
2 parents 298655f + 0af200c commit ba36ce8

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

packages/core/src/bag3d/core/sqlfiles/webservice_tiles.sql

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ WITH validate_compressed_files_cast AS (SELECT tile_id::text
55
WHEN cj_zip_ok ISNULL OR length(cj_zip_ok) = 0
66
THEN NULL::boolean
77
ELSE cj_zip_ok::boolean END AS cj_zip_ok
8+
, CASE
9+
WHEN cj_file_ok ISNULL OR length(cj_file_ok) = 0
10+
THEN NULL::boolean
11+
ELSE cj_file_ok::boolean END AS cj_file_ok
812
, CASE
913
WHEN cj_nr_building ISNULL OR length(cj_nr_building) = 0
1014
THEN NULL::int
@@ -92,6 +96,13 @@ WITH validate_compressed_files_cast AS (SELECT tile_id::text
9296
length(cj_schema_warnings) = 0
9397
THEN NULL::boolean
9498
ELSE cj_schema_warnings::boolean END AS cj_schema_warnings
99+
, CASE
100+
WHEN cj_attributes_with_errors ISNULL OR
101+
length(cj_attributes_with_errors) = 0
102+
THEN NULL::text[]
103+
ELSE string_to_array(
104+
replace(replace(cj_attributes_with_errors, '[', ''), ']', ''),
105+
',')::text[] END AS cj_attributes_with_errors
95106
, CASE
96107
WHEN cj_lod ISNULL OR length(cj_lod) = 0
97108
THEN NULL::text[]
@@ -104,6 +115,11 @@ WITH validate_compressed_files_cast AS (SELECT tile_id::text
104115
WHEN obj_zip_ok ISNULL OR length(obj_zip_ok) = 0
105116
THEN NULL::boolean
106117
ELSE obj_zip_ok::boolean END AS obj_zip_ok
118+
, CASE
119+
WHEN obj_file_ok ISNULL OR
120+
length(obj_file_ok) = 0
121+
THEN NULL::boolean
122+
ELSE obj_file_ok::boolean END AS obj_file_ok
107123
, CASE
108124
WHEN obj_nr_building ISNULL OR
109125
length(obj_nr_building) = 0
@@ -190,6 +206,13 @@ WITH validate_compressed_files_cast AS (SELECT tile_id::text
190206
length(gpkg_nr_invalid_2d_geom) = 0
191207
THEN NULL::int
192208
ELSE gpkg_nr_invalid_2d_geom::int END AS gpkg_nr_invalid_2d_geom
209+
, CASE
210+
WHEN gpkg_attributes_with_errors ISNULL OR
211+
length(gpkg_attributes_with_errors) = 0
212+
THEN NULL::text[]
213+
ELSE string_to_array(
214+
replace(replace(gpkg_attributes_with_errors, '[', ''), ']', ''),
215+
',')::text[] END AS gpkg_attributes_with_errors
193216
, gpkg_download::text
194217
, gpkg_sha256::text
195218
FROM ${validate_compressed_files})

0 commit comments

Comments
 (0)