At Bird Company, an order is recorded in two separate tables as follows. The table titled orders

Question:

At Bird Company, an order is recorded in two separate tables as follows. The table titled orders contains a single record of header information for each order in the following fields: order number (numeric data), customer number (character data), order type (character data), subtotal (numeric data), and shipping charges (numeric data). The items ordered and related amounts for each order (a €œmany- to- one€ relationship) are recorded in the table titled order details. Each entry in the order details table contains the fields order number (numeric data), the vendor product number of the item (character data), quantity of the item (numeric data), and price of the item (numeric data). Sample records are illustrated below.

At Bird Company, an order is recorded in two separate

Required
a. Write an SQL query that retrieves all of the fields for each record and all of the records from the orders table.
b. Write an SQL query that retrieves order number and vendor product number for all of the records from the order details table.
c. Write an SQL query that retrieves order number and order type for all of the records from the orders table. The query should sort the data ascending by order number. d. Write an SQL query that retrieves order number and vendor product number for records from the order details
Table, selecting only records that have a price that is greater than 20.00.
e. Write an SQL query that retrieves order number and customer number for records from the orders table, selecting only records that have €œfax€ as the order type. The query should sort the data descending by customer number.
f. Write an SQL query that displays the total number of records in the order details table.
g. Write an SQL query that displays the average value of shipping charges for all of the records in the orders table.
h. Write an SQL query that displays the order number and the total amount of the subtotal and shipping charges for each record for all of the records in the orders table.
i. Write an SQL query that displays the order number and the customer number from the orders table and the corresponding vendor product number from the order details table for all of the orders in the orders table.
j. Write an SQL query that displays the order number and the shipping charges from the orders table and the corresponding vendor product number and quantity from the order details table for all of the orders that have an order type of either €œfax€ or€œemail.€

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question

Accounting Information Systems

ISBN: 9780132871938

11th Edition

Authors: George H. Bodnar, William S. Hopwood

Question Posted: