I have a simple table
mytable
id int
time_stamp tiemstamp
value int
tid int
I want to find the max id for each individual tid in my table.
if I did it one by one it would be:
select max(id) from mytable where tid = 12345;
but how can I do something more like:
select concat(tid,':',id) from
SELECT tid,max(id) FROM mytable
GROUP BY tid
Le 10 sept. 2010 à 19:12, Bryan Cantwell a écrit :
I have a simple table
mytable
id int
time_stamp tiemstamp
value int
tid int
I want to find the max id for each individual tid in my table.
if I did it one by one it would be:
select