Professional Documents
Culture Documents
Assignment # 5 SQL
Assignment # 5 SQL
Assignment # 5 SQL
1) The output will list the number and name of all customers represented by sales 35 or that
2) The output will list the description of all parts that are located in warehouse 3 or which there
3) The output will list the customer number, Name, Street, and city zip for all customers whose
4) Based on the code above, list the number, name, street and credit limit of all customers.
5) Output will list num name limit, and repnum of customers whose rep- num 35 and also credit
6) Output will list the number, name, limit and rep num of all customers if either the customer
7) Output will list the number name of all the customers whose rep rum is equal to rename in
the rep table; the last name should be Perez, and his first name should be JUAN.
8) According to the E-R Diagram, the database has five tables: Rep, Customer, Orders, Order
Line, and Part. The following is the connection between these tables:
a) The relationship between the table rep and the table customer is as follows: Rep Selles
Products to Customer. Because one Rep may offer items to several consumers, the connection
a single Customer may make several Orders, the connection between Customer and Orders is
c) The following is the relationship between Table Orders and Table OrderLine: Orders are made
up of OrderLine. Because one Order might include several OrderLine, the connection between
d) The following is the relationship between Table OrderLine and Table Part: OrderLine
Belongs to Part. The Component table includes information about the OrderLine, such as the
description and warehouse where the order part is held. Because one Part might include several
Step 2: In Conclusion
According to the E-R Diagram, the database has five tables: Rep, Customer, Orders, OrderLine,
a) The relationship between the table rep and the table customer is as follows: Rep Selles
Products to Customer. Because one Rep may offer items to several consumers, the connection
b) Customer Places Orders is the relationship between table customers and table orders. Because
a single Customer may make several Orders, the connection between the Customer and Orders is
one to many.
c) The following is the relationship between Table Orders and Table OrderLine: Orders are made
up of OrderLine. Because one Order might include several OrderLine, the connection between
d) The following is the relationship between Table OrderLine and Table Part: OrderLine Belongs
to Part. The Component table includes information about the OrderLine, such as the description
and warehouse where the order part is held. Because one Part might include several OrderLines,