Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

List the statements for the following transaction using the relations below: jsm

ID: 3715901 • Letter: L

Question

List the statements for the following transaction using the relations below: jsmith orders 1 book with ISBN 1045678900 on April 24, 2018.

Note: Bold Represents Primary Key. Italizied attributes in some relations denote foregin keys.

MEMBER(last_name, first_name, email, password, user, street, city, state, zip, card_type, card_no, expiration, name_on_card)

BOOKS_FOR_SALE(listing_no, seller, isbn, condition, price)

ORDERS(order_no, buyer, order_date, total)

ITEMS(order_no, listing_no)

BOOK(isbn, title, author, edition, publisher, keywords)

Explanation / Answer

As the transaction is an Order, We need to insert the record in ORDERS and ITEMS tables. For Insert into ORDERS, We need price of the book which can be retrieved from BOOKS_FOR_SALE table. Also we need listing_no to store in ITEMS which also can be retrieved from BOOKS_FOR_SALE table. For these two we need to create local varaibles and fetch values in these variables.

Suppose We are inserting order with Order number as 1. Insert the record in ORDERS as well as ITEMS using above variables.

These are the complete set of statements for above transaction. Please feel free to ask any questions about this.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote