# location ## Purpose The **location** table defines the physical structure of the facility through a hierarchical zone and sector system. It is used to assign bedrooms, cells, SCP containment cells to specific areas within the facility. ## Columns | Field | Type | Description |--------|----------|-------------------------------------------------------------------------------| | id_loc | SMALLINT | Unique location identifier (PK, AUTO_INCREMENT) | zone | ENUM | Facility zone classification | sector | ENUM | Subdivision of a zone used for spatial organization and navigation (NULLABLE) |---------------------------------------------------------------------------------------------------| ### ENUM values - zone = ('SZ','EZ','LCZ','HCZ') - sector = ('A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z') ## Relationships - Referenced by **scp.id_loc** to define SCP containment locations. - Referenced by **task.id_loc** to define task locations. - Referenced by **activity_log.id_loc** to record where an activity occurred. - Referenced by **incident_log.id_loc** to record where an incident occurred. - Referenced by **bedroom.id_loc** to assign bedrooms to facility areas. - Referenced by **cell.id_loc** to assign D-Class cells to facility areas. ## Rules - when `sector` value is NULL we are referring an entire zone ## Example output +--------+------+--------+ | id_loc | zone | sector | +--------+------+--------+ | 10 | LCZ | C | +--------+------+--------+