Skip to content

Latest commit

 

History

History
39 lines (27 loc) · 708 Bytes

101_product_sales_analysis_i.md

File metadata and controls

39 lines (27 loc) · 708 Bytes

SQL Everyday #101

Product Sales Analysis I

Site: LeetCode
Difficulty per Site: Easy

Problem

Write a solution to report the product_name, year, and price for each sale_id in the Sales table.

Return the resulting table in any order. [Full Description]

Submitted Solution

-- Submitted Solution
SELECT
    p.product_name
    ,s.year
    ,s.price
FROM Sales AS s
JOIN Product AS p ON s.product_id = p.product_id
;

Site Solution

-- LeetCode Solution 
-- Site solution essentially the same.

Notes

TODO

Go to Table of Contents
Go to Overview