The customer table
The customer
table contains information about all customers described as follows:
Column |
Description |
---|---|
|
A primary key used to uniquely identify each customer in the table. |
|
A foreign key identifying the customer's "home store". Customers are not limited to renting only from this store, but this is the store they generally shop at. |
|
The customer's first name. |
|
The customer's last name. |
|
The customer's e-mail address. |
|
A foreign key
identifying the customer's address in the |
|
Indicates if the customer is an active customer. Setting this to |
|
The date when the customer was added to the database. |
|
The most recent row update. It has not been used in this book. |
This information of all the customers is shown in a pictorial format in the following screenshot:
![](https://static.packt-cdn.com/products/9781782162247/graphics/2247OS_AppendixA_004.jpg)
The address table
The address
table contains the address information of customers, staff, and stores described as follows:
Column |
Description |
---|---|
|
A primary key used to uniquely identify each customer in the table. |
|
A line of address information. |
|
Another line of address information that is used if the first line is not enough. |
|
The region of an address; this may be a state, province, prefecture, and so on. |
|
A foreign key identifying the city of the address in the city table. |
|
The postal code or zip code of the address. |
|
The phone number for the address. |
|
The most recent row update. It has not been used in this book. |
An example of the address
table is shown in the following screenshot:
![](https://static.packt-cdn.com/products/9781782162247/graphics/2247OS_AppendixA_005.jpg)
The city table
The city
table contains a list of cities described as follows:
Column |
Description |
---|---|
|
A primary key used to uniquely identify each city in the table. |
|
The name of the city. |
|
A foreign key identifying the country the city belongs to in the |
|
The most recent row update. It has not been used in this book. |
An example of the city
table is shown in the following screenshot:
![](https://static.packt-cdn.com/products/9781782162247/graphics/2247OS_AppendixA_006.jpg)
The country table
The country
table contains a list of countries described as follows:
Column |
Description |
---|---|
|
A primary key used to uniquely identify each country in the table. |
|
The name of the country. |
|
The most recent row update. It has not been used in this book. |
An example of the country
table is shown in the following screenshot:
![](https://static.packt-cdn.com/products/9781782162247/graphics/2247OS_AppendixA_007.jpg)