CREATE VIEW CUSTOMER_ADDRESSES AS
SELECT cust.customerID, cust.lastName, cust.firstName,
bill.line1 as billLine1, bill.line2 as billLine2, bill.city as billCity,
bill.state as billState, bill.zip as billZip,
ship.line1 as shipLine1, ship.line2 as shipLine2, ship.city as shipCity,
ship.state as shipState, ship.zip as shipZip
FROM customers cust, addresses bill, addresses ship
WHERE cust.shippingaddressid = ship.addressid
and cust.billingaddressid = bill.addressid