Tell me how you would denormalize a table.
For this exercise, use the normalized tables provided to produce a flattened reporting result. Preserve every order-line record, including records with missing customer or product details.
line_id, order_id, order_date, customer_name, region, sku, product_name, product_family, quantity, unit_price, and line_totalNULL, and calculate line_total as quantity multiplied by unit priceorder_date, then order_id, then line_id| Column | Type | Description |
|---|---|---|
| customer_idPK | INT | Unique customer identifier |
| customer_name | VARCHAR(100) | Customer or account name |
| region | VARCHAR(50) | Customer sales region |
| Column | Type | Description |
|---|---|---|
| product_idPK | INT | Unique product identifier |
| sku | VARCHAR(40) | Stock keeping unit |
| product_name | VARCHAR(120) | Product name |
| product_family | VARCHAR(80) | Product family or category |
| Column | Type | Description |
|---|---|---|
| line_idPK | INT | Unique order-line identifier |
| order_id | INT | Order identifier |
| order_date | DATE | Date the order was placed |
| customer_id | INT | Referenced customer identifier |
| product_id | INT | Referenced product identifier |
| quantity | INT | Units ordered |
| unit_price | NUMERIC(10,2) | Price per unit |