"content":"<p>Table: <code>Sales</code></p>\n\n<pre>\n+-------------+-------+\n| Column Name | Type |\n+-------------+-------+\n| sale_id | int |\n| product_id | int |\n| year | int |\n| quantity | int |\n| price | int |\n+-------------+-------+\n(sale_id, year) is the primary key (combination of columns with unique values) of this table.\nproduct_id is a foreign key (reference column) to <code>Product</code> table.\nEach row of this table shows a sale on the product product_id in a certain year.\nNote that the price is per unit.\n</pre>\n\n<p> </p>\n\n<p>Table: <code>Product</code></p>\n\n<pre>\n+--------------+---------+\n| Column Name | Type |\n+--------------+---------+\n| product_id | int |\n| product_name | varchar |\n+--------------+---------+\nproduct_id is the primary key (column with unique values) of this table.\nEach row of this table indicates the product name of each product.\n</pre>\n\n<p> </p>\n\n<p>Write a solution to report the <code>product_name</code>, <code>year</code>, and <code>price</code> for each <code>sale_id</code> in the <code>Sales</code> table.</p>\n\n<p>Return the resulting table in <strong>any order</strong>.</p>\n\n<p>The result format is in the following example.</p>\n\n<p> </p>\n<p><strong class=\"example\">Example 1:</strong></p>\n\n<pre>\n<strong>Input:</strong> \nSales table:\n+---------+------------+------+----------+-------+\n| sale_id | product_id | year | quantity | price |\n+---------+------------+------+----------+-------+ \n| 1 | 100 | 2008 | 10 | 5000 |\n| 2 | 100 | 2009 | 12 | 5000 |\n| 7 | 200 | 2011 | 15 | 9000 |\n+---------+------------+------+----------+-------+\nProduct table:\n+------------+--------------+\n| product_id | product_name |\n+------------+--------------+\n| 100 | Nokia |\n| 200 | Apple |\n| 300 | Samsung |\n+------------+--------------+\n<strong>Output:</strong> \n+--------------+-------+-------+\n| product_name | year | price |\n+--------------+-------+-------+\n| Nokia | 2008 | 5000 |\n| Nokia | 2009 | 5000 |\n| Apple | 2011 | 9000 |\n+--------------+-------+-------+\n<strong>Explanation:</strong> \nFrom sale_id = 1, we can conclude that Nokia was sold for 5000 in the year 2008.\nFrom sale_id = 2, we can conclude that Nokia was sold for 5000 in the year 2009.\nFrom sale_id = 7, we can conclude that Apple was sold for 9000 in the year 2011.\n</pre>\n",