Company: Zomato_product_Analyst
Difficulty: medium
Problem Description You are given two tables containing order information. The Orders table includes the order dates, while the OrderDetails table contains item details such as price and quantity. Write a SQL query to calculate the total monthly revenue for each year based on the order dates. The revenue for a single item is calculated using the formula: unitprice * qty . Schema Table: Orders +-------------+---------+ | Column Name | Type | +-------------+---------+ | order_id | INT | | order_date | DATE | +-------------+---------+ - order_id is the primary key for this table. - order_date represents the date the order was placed. Table: OrderDetails +-------------+---------+ | Column Name | Type | +-------------+---------+ | order_id | INT | | unitprice | INT | | qty | INT | +-------------+---------+ - This table may contain multiple rows per order_id (representing multiple items per order). - order_id is a foreign key referencing Orders.order_id. Required Output The output should con