Could you please help me to solve this Below Query:

I have below table of data.

| EmpNo | Name | City |
| --- | --- | --- |
| 1 | John | US |
| 2 | Miranda | US |
| 3 | Pete | US |
| 4 | Jack | US |
| 5 | Kathy | UK |
| 6 | Tanni | UK |
| 7 | Sally | UAE |

I want output as like below:

| City | Name1 | Name2 |
| --- | --- | --- |
| US | John | Miranda |
| US | John | Pete |
| US | John | Jack |
| US | Miranda | Pete |
| US | Miranda | Jack |
| US | Pete | Jack |
| UK | Kathy | Tanni |

PLSQL we can write block to get this output. But is it possible to get output using SQL code alone?