Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save mymindwentblvnk/9e2ab4d92750baba8b624b46a737036d to your computer and use it in GitHub Desktop.
Save mymindwentblvnk/9e2ab4d92750baba8b624b46a737036d to your computer and use it in GitHub Desktop.
This creates a external BigQuery table for the data extracted from https://github.com/mymindwentblvnk/vgn-departure-extractor
CREATE EXTERNAL TABLE `me-playground.raw.ext_departure_information6`
(
VAGKennung STRING,
Haltestellenname STRING,
VGNKennung INT64,
Metadata STRUCT<VERSION STRING, `Timestamp` STRING>,
Abfahrten ARRAY<STRUCT<
Linienname STRING,
Haltepunkt STRING,
Richtung STRING,
Richtungstext STRING,
AbfahrtszeitSoll STRING,
AbfahrtszeitIst STRING,
Produkt STRING,
Longitude FLOAT64,
Latitude FLOAT64,
Fahrtnummer INT64,
Fahrtartnummer INT64,
Fahrzeugnummer STRING,
Prognose BOOL,
HaltesteigText STRING>
>
)
OPTIONS (
format = "JSON",
uris = ['gs://vgn-departures-archive/*'],
ignore_unknown_values = true
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment