Product_info Assignment | Homework For You

  • users(email, name, pwd, city, gender)
  • products(pid, descr)
  • sales(sid, lister, pid, edate, descr, cond, rprice)
  • bids(bid, bidder, sid, bdate, amount)
  • items(sid, no, pid, descr)
  • reviews(reviewer, reviewee, rating, rtext, rdate)
  • previews(rid, pid, reviewer, rating, rtext, rdate)Homework For You

Clarifications: The Language is in sqlite3. The lister is represented by an email, bidder is represented by an email.

  1. Create a view called product_info with columns pid, descr, revcnt, rating, rating6, and salecnt. The view includes for each product the product id, the description, the number of reviews, the average rating, the average rating based on the reviews written within the past 6 months, and the number of different sales that are either associated to the product or have an item that is associated to the product. Include products with no reviews or sales in the output with zero counts (if applicable) or null values.
  2. Using the view created in the previous question, find users whose sales are all associated to hot products. A product is hot if its average rating is larger than 4 and its sale count is larger than the average sale count. Get Finance homework help today

Don't use plagiarized sources. Get Your Custom Essay on
Product_info Assignment | Homework For You
Just from $13/Page
Order Essay

STAY HOME, SAVE LIVES. Order your paper today and save 15% with the discount code FLIX