Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Patch] - Adds the rest of level to the necessary base queries #196

Merged
merged 1 commit into from
May 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion task-force-docs/base/infrastructure.sql
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ SELECT
tags['surface'] AS surface,

-- Overture's concept of `layer` is called level
tags['layer'] AS level,
TRY_CAST(tags['layer'] AS int) AS level,

-- Wikidata is a top-level property in the OSM Container
tags['wikidata'] as wikidata,
Expand Down
3 changes: 2 additions & 1 deletion task-force-docs/base/land.sql
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ SELECT
tags['wikidata'] as wikidata,

-- Overture's concept of `layer` is called level
tags['layer'] AS level,
TRY_CAST(tags['layer'] AS int) AS level,

-- Elevation as integer (meters above sea level)
TRY_CAST(tags['ele'] AS integer) AS elevation,
Expand Down Expand Up @@ -307,6 +307,7 @@ SELECT
)
) ] as sources,
NULL AS wikidata,
NULL AS level,
NULL AS elevation,
wkt AS wkt_geometry
FROM {daylight_earth_table}
Expand Down
3 changes: 2 additions & 1 deletion task-force-docs/base/land_use.sql
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ SELECT
sources,
wikidata,
surface,
level,
elevation,
wkt_geometry
FROM (
Expand Down Expand Up @@ -273,7 +274,7 @@ FROM (
) ] AS sources,

-- Overture's concept of `layer` is called level
tags['layer'] AS level,
TRY_CAST(tags['layer'] AS int) AS level,

-- Wikidata is a top-level property in the OSM Container
tags['wikidata'] as wikidata,
Expand Down
3 changes: 2 additions & 1 deletion task-force-docs/base/water.sql
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ SELECT
tags['wikidata'] as wikidata,

-- Overture's concept of `layer` is called level
tags['layer'] AS level,
TRY_CAST(tags['layer'] AS int) AS level,

-- Elevation is common on some ponds / lakes.
TRY_CAST(tags['ele'] AS integer) AS elevation,
Expand Down Expand Up @@ -324,6 +324,7 @@ SELECT
) ] as sources,
-- Wikidata is a top-level property in the OSM Container
NULL as wikidata,
0 as level, -- it's the ocean, does it go lower?
-- Other type=water top-level attributes
0 AS elevation,
TRUE AS is_salt,
Expand Down
Loading