I use this query to get the newest 1 entry:
SELECT * FROM Data ORDER BY ID DESC LIMIT 1
I am using node-mysql in nodeJS, I would like to use the
rows[0].Data
So I can get the 4 newest entries in separate variables, how can I achieve this?
I am aware that I can up the DESC LIMIT to 4, to limit the results, but am still failing trying to get more than 1 result.
Aucun commentaire:
Enregistrer un commentaire