order_addresses table
The order_addresses table in the E-commerce Database Schema schema has 11 columns, keyed by id, with 1 foreign key to orders.
A frozen copy of the address at checkout. Editing the address book never rewrites shipping history.
Columns (11)
| Column | Type | Constraints | Description |
|---|---|---|---|
| id | uuid | primary key | |
| order_id | uuid | not null, references orders.id | |
| type | address_type | not null | |
| full_name | varchar(120) | not null | |
| line1 | varchar(255) | not null | |
| line2 | varchar(255) | ||
| city | varchar(120) | not null | |
| region | varchar(120) | ||
| postal_code | varchar(20) | not null | |
| country_code | char(2) | not null | |
| phone | varchar(32) |
Indexes (1)
(order_id, type)unique
Relationships
order_addresses.order_idreferencesorders.id