I have a table sales:
SalesID. Date. Geography
1. 2020-01. Italy
1. 2020-01. France
1. 2020-01. UK
2. 2020-02. Italy
2. 2002-02. Canada
3. 2002-08. France
I would like to display only top 2 Geography and pivot:
Expected result:
SalesID. Date. Geography 1. Geography2.
1. 2020-01. Italy. France
2. 2020-02. Italy. France.
3. 2020-08. France
What I try so far https://dbfiddle.uk/?rdbms=sqlserver_2019&fiddle=565f80f146fe2a72096b31fc0baba3ad
How to modify it?