Columns
| Column | Type | Size | Nulls | Auto | Default | Children | Parents | Comments | ||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| material_use_id | INT | 10 | √ | null |
|
|
Primary key for material_use, auto-incrementing |
|||||||
| heritage_site_id | INT | 10 | null |
|
|
FK. Heritage_site_id links to heritage_site |
||||||||
| construction_id | INT | 10 | √ | NULL |
|
|
FK. Links to a particular phase of construction. |
|||||||
| commodity_id | INT | 10 | null |
|
|
FK commodity_id links to commodity (material and material_source) |
||||||||
| location_id | INT | 10 | √ | NULL |
|
|
FK. Link to location |
|||||||
| use_feature_id | INT | 10 | √ | NULL |
|
|
FK. Links to dictionary of feature types. |
|||||||
| is_original | TINYINT | 3 | √ | NULL |
|
|
Whether the material is original or not |
|||||||
| material_condition_id | INT | 10 | √ | NULL |
|
|
FK. Links to dictionary of material condition |
|||||||
| material_use_detail | TEXT | 65535 | √ | NULL |
|
|
Described where the material is used |
|||||||
| material_position_id | INT | 10 | √ | NULL |
|
|
FK interior or exterior |
|||||||
| source_distance_id | INT | 10 | √ | NULL |
|
|
FK. How far away the material came from. |
|||||||
| documentary_sources | TEXT | 65535 | √ | NULL |
|
|
Source of the information (format for front end) |
|||||||
| entered_by | VARCHAR | 500 | √ | NULL |
|
|
||||||||
| entered_date | DATETIME | 19 | √ | current_timestamp() |
|
|
||||||||
| modified_by | VARCHAR | 500 | √ | NULL |
|
|
||||||||
| modified_by_date | DATETIME | 19 | √ | NULL |
|
|
Indexes
| Constraint Name | Type | Sort | Column(s) |
|---|---|---|---|
| material_use_s_pk | Primary key | Asc | material_use_id |
| commodity_id | Performance | Asc | commodity_id |
| construction_id | Performance | Asc | construction_id |
| fabrication_centre_id | Performance | Asc | location_id |
| heritage_site_id | Performance | Asc | heritage_site_id |
| material_condition_id | Performance | Asc | material_condition_id |
| material_position_id | Performance | Asc | material_position_id |
| PRIMARY | Must be unique | Asc | material_use_id |
| source_distance_id | Performance | Asc | source_distance_id |
| use_feature_id | Performance | Asc | use_feature_id |



