How can I add a column from a select query but the value from the new column will be the row count of the select query for example.
select quantity from menu;
and returns like this
+--------+
|quantity|
+--------+
| 50 |
| 32 |
| 23 |
+--------+
but I want somthing like this
+----------+--------+
|new column|quantity|
+----------+--------+
| 1 | 50 |
| 2 | 32 |
| 3 | 23 |
+----------+--------+
the new column should start from 1 and end from row count of the select query statement. Any answer would help Thanks