I want to get row numbers from list. I tried `ROW_NUMBER()` and `DENSE_RANK` with different variations, getting just duplicated rows.

With my code (code is below) SQL returns list of all orders, which are including some product id's of order 20 (those three products `'1013', '1024', '1025'`).

Problem is when I try to get `row_numbers` out of that list, it duplicate some rows because there are more than one product including in that order.

With my code it look like this:

```
Order_number
20
22
27

```

With `ROW_NUMBER()` it looks like this and that is problem:

```
Row_number | Order_number
1            20
2            20
3            20
4            22
5            27
6            27

```

I want it look like this:

```
Row_number | Order_number
1            20
2            22
3            27

```

```
SELECT DISTINCT ORDER_ID AS 'ORDERS, WHICH HAVE AT LEAST ONE PRODUCT OF ORDER 20'

FROM ORDERS

INNER JOIN STORAGE ON ORDERS.PRODUCT_ID = STORAGE.PRODUCT_ID

WHERE STORAGE.PRODUCT_ID IN ('1013', '1024', '1025');

```