// Use DBML to define your database structure // Docs: https://dbml.dbdiagram.io/docs Table seeds [note: 'Table contains the URIs which are used for the initial scraping.'] { seed_id integer [primary key] uri text [not null, unique] region_id integer [not null, ref: > regions.region_id] } Table regions { region_id integer [primary key] name varchar(255) [not null] } Table properties { property_id integer [primary key] property_platform_id varchar(255) [unique, not null, note: 'uuid from platform beeing used'] seed_id integer [not null, ref: > seeds.seed_id] check_data json [note: 'for storing data, which is beeing used for consistency checks. E. g. geo_dates or title'] last_found timestamp created_at timestamp } Table extractions { extraction_id integer [primary key] property_id integer [unique, ref: > properties.property_id] body text [not null] header text [not null] type types [not null] created_at timestamp [not null] } enum types { property calendar offer } Table exceptions { exception_id integer [primary key] exception json [not null, note: "exception while scraping (e. g. HTTP error message) and called url."] type types [not null] property_id integer [not null, ref: > properties.property_id, note: "either a property_id"] }