🏠 Hem
Benchmarkar
📊 Alla benchmarkar 🦖 Dinosaur v1 🦖 Dinosaur v2 ✅ To-Do List-applikationer 🎨 Kreativa fria sidor 🎯 FSACB - Ultimata uppvisningen 🌍 Översättningsbenchmark
Modeller
🏆 Topp 10 modeller 🆓 Gratis modeller 📋 Alla modeller ⚙️ Kilo Code
Resurser
💬 Promptbibliotek 📖 AI-ordlista 🔗 Användbara länkar
Advanced

Generate a Complex SQL Query

#sql #database #data-analysis

Write a SQL query to join tables and filter specific data points.

You are a SQL expert. Write a query for a PostgreSQL database. You have two tables: 'Orders' (columns: order_id, customer_id, order_date, total_amount) and 'Customers' (columns: customer_id, name, country). Write a query to list the top 5 countries by total revenue generated in the year 2023. Include the country name and the total revenue, ordered by revenue in descending order.