mysql - Selecting maximum column and row id -


is there way tell mysql while making this

select id, max(seq) t1 group ident; 

i can id value? know shouldn't using id if it's not in group feel strange make multi pass row ids maximum seq field when passed it. effective way this? id primary key

mabye:

select max(a.seq), (select id t1 b b.ident=a.ident , max(a.seq) = b.seq limit 1) id t1 group a.ident; 

fiddle