kopia lustrzana https://github.com/osm2vectortiles/osm2vectortiles
Rename column names in mapping-qa-report
rodzic
e107babb60
commit
71c402944e
|
@ -31,17 +31,17 @@ $$ LANGUAGE plpgsql;
|
|||
CREATE OR REPLACE FUNCTION compare_layer_feature_count(id text, iosmlist TEXT[], ilayerlist TEXT[])
|
||||
RETURNS TABLE (
|
||||
tid text,
|
||||
all_features bigint,
|
||||
used_features bigint,
|
||||
osmlist TEXT[],
|
||||
layerlist TEXT[]
|
||||
db_features bigint,
|
||||
vt_features bigint,
|
||||
tables TEXT[],
|
||||
layers TEXT[]
|
||||
) AS $$
|
||||
BEGIN
|
||||
RETURN QUERY
|
||||
SELECT id as tid,
|
||||
count_osmid(iosmlist) as all_features,
|
||||
count_osmid(ilayerlist) as used_features,
|
||||
iosmlist as osmlist,
|
||||
ilayerlist as layerlist;
|
||||
count_osmid(iosmlist) as db_features,
|
||||
count_osmid(ilayerlist) as vt_features,
|
||||
iosmlist as tables,
|
||||
ilayerlist as layers;
|
||||
END;
|
||||
$$ LANGUAGE plpgsql;
|
||||
|
|
|
@ -70,6 +70,12 @@ WITH vlayers AS (
|
|||
array['mountain_peak_label_layer']
|
||||
)
|
||||
)
|
||||
SELECT *, round((used_features::numeric * 100) / all_features::numeric, 2) as percent
|
||||
SELECT
|
||||
tid,
|
||||
db_features,
|
||||
vt_features,
|
||||
round((db_features::numeric * 100) / vt_features::numeric, 2) as percent,
|
||||
tables,
|
||||
layers
|
||||
FROM vlayers
|
||||
ORDER BY tid;
|
||||
|
|
Ładowanie…
Reference in New Issue