Table: damage
Description (EN): This table stores the universal, high-level attributes—such as identification and geographical location for all damages following the occurrance of an event. Specific types of damages (like damages to artistic goods, damages on building functionality, or other) store their specialized data in separate sub-tables that share the same ID.
Column Structure
| Column | Data type | Definition | Example value | Constraint? | Geometry? | Comments |
|---|---|---|---|---|---|---|
id |
BIGINT | Unique identifier for the damage | 3 |
PK | No | Acts as the universal ID across all sub-type tables |
estimated_value |
BIGINT | [...] | - | - | No | - |
component_id |
BIGINT | [...] | - | FK | No | Pointing to id of entity component |
date |
TIMESTAMP | [...] | [...] | - | No | - |
end_date |
TIMESTAMP | [...] | [...] | - | No | - |
start_end |
TIMESTAMP | [...] | [...] | - | No | - |
survey_id |
BIGINT | [...] | [...] | FK | No | Pointing to id of entity survey |
country |
VARCHAR | [...] | [...] | - | No | - |
county |
VARCHAR | [...] | [...] | - | No | - |
description |
VARCHAR | [...] | [...] | - | No | - |
hamlet |
VARCHAR | [...] | [...] | - | No | - |
house_number |
VARCHAR | [...] | [...] | - | No | - |
postcode |
VARCHAR | [...] | [...] | - | No | - |
road |
VARCHAR | [...] | [...] | - | No | - |
state |
VARCHAR | [...] | [...] | - | No | - |
town |
VARCHAR | [...] | [...] | - | No | - |
geometry |
GEOMETRY | Spatial representation of the damage entity | [...] | - | No | - |
coordinates_inferred |
BOOLEAN | [...] | [...] | - | No | - |
sendai_indicator |
VARCHAR | [...] | [...] | - | No | - |
Relationships
Because damage is one of the core entities of the schema, it has extensive relationships:
- Has Sub-types (Inheritance): The following tables inherit from
damageand share itsid:damage_artistic_gooddamage_building_functionalitydamage_building_not_structuraldamage_building_structuraldamage_business_operationsdamage_church_structuredamage_goodsdamage_network_componentdamage_network_servicedamage_peopledamage_productdamage_vehiclesdamage_whole_structurefarm_damage
- Affects:
component(One or more damages affect a component or its subclasses) - Is recorded by:
survey(One or more damages is reported in a survey) - Documented in:
attachment(A damage is reported in one or more attachments) - Results in:
economic_loss