Itech data modelling lab topicintroduction sql continued questions
ITECH 2004 DATA MODELLING
Lab 7Correlated Subquery is a sub-query that uses values from the outer query. In this case the inner query must be executed for every row of outer query. While A regular subquery can be simply defined as a query within another query.Subqueries can be used with SELECT, UPDATE, INSERT, DELETE statements along with expression operator.
2. What does it mean to say that SQL operators are set-oriented? When commands work over entire tables at a time, not row by row.
Exercises
6. The LargeCo database (see Figure E6.1) stores data for a company that sells paint products. The company tracks the sale of products to customers. The database keeps data on customers (LGCUSTOMER), sales (LGINVOICE), products (LGPRODUCT), which products are on which invoices (LGLINE), employees (LGEMPLOYEE), the salary history of each employee
(LGSALARY_HISTORY), departments (LGDEPARTMENT), product brands (LGBRAND), vendors (LGVENDOR), and which vendors supply each product (LGSUPPLIES). Some of the tables contain only a few rows of data, while other tables are quite large; for example, there are only eight departments, but more than 3,300 invoices containing over 11,000 invoice lines.
a. | Page 1 of 5 | |
---|---|---|
This study source was downloaded by 100000851205819 from CourseHero.com on 08-25-2022 05:45:56 GMT -05:00
This study source was downloaded by 100000851205819 from CourseHero.com on 08-25-2022 05:45:56 GMT -05:00