Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lære Challenge: Top Sales per Region | Introduction to Window Functions
Window Functions in SQL

bookChallenge: Top Sales per Region

Opgave

Swipe to start coding

Write a query to find the highest sale amount and corresponding employee for each region using window functions.

  • Assign a row number to each sale within its region, ordering by the sale amount in descending order.
  • Select the region, employee ID, and sale amount for the row with the highest sale in each region.

Løsning

Var alt klart?

Hvordan kan vi forbedre det?

Tak for dine kommentarer!

Sektion 1. Kapitel 4
single

single

Spørg AI

expand

Spørg AI

ChatGPT

Spørg om hvad som helst eller prøv et af de foreslåede spørgsmål for at starte vores chat

Suggested prompts:

Can you explain this in simpler terms?

What are some examples related to this topic?

Where can I learn more about this?

close

bookChallenge: Top Sales per Region

Stryg for at vise menuen

Opgave

Swipe to start coding

Write a query to find the highest sale amount and corresponding employee for each region using window functions.

  • Assign a row number to each sale within its region, ordering by the sale amount in descending order.
  • Select the region, employee ID, and sale amount for the row with the highest sale in each region.

Løsning

Switch to desktopSkift til skrivebord for at øve i den virkelige verdenFortsæt der, hvor du er, med en af nedenstående muligheder
Var alt klart?

Hvordan kan vi forbedre det?

Tak for dine kommentarer!

Sektion 1. Kapitel 4
single

single

some-alt