i want to get the most recently added data from MySQL
for example, if we have a table named test with column : id
the data is inserted as follows: 2, 4, 1, 3
when i type this query :
, it returns 4
but i want a query that returns 3 (the last inserted data)
can i do this?
for example, if we have a table named test with column : id
the data is inserted as follows: 2, 4, 1, 3
when i type this query :
Code:
SELECT * FROM test ORDER BY id DESC LIMIT 1
but i want a query that returns 3 (the last inserted data)
can i do this?
Comment