finish presentation.

This commit is contained in:
matt
2023-05-18 19:55:15 -07:00
parent 3f7b3ad467
commit 398228f02c
18 changed files with 975 additions and 184 deletions

View File

@@ -348,6 +348,7 @@ def create_elections_table():
row_number() over() as id
,type
,date
,winner
FROM df
""")
@@ -359,6 +360,7 @@ def create_elections_table():
,e.id as election_id
,e.date as election_date
,s.published_at as publish_date
,e.winner as winner
FROM (
SELECT
DISTINCT
@@ -373,6 +375,7 @@ def create_elections_table():
,publish_date
,election_date
,election_id
,winner
FROM cte
)
SELECT
@@ -380,6 +383,7 @@ def create_elections_table():
,publish_date
,election_date
,election_id
,winner
FROM windowed
WHERE rn = 1
""")