mysql - sql error (1241): operand should contain 1 column(s) - order by dates -
i'm trying find last deployment associated serial number, , without getting latest date, multiple lines particular serial number. i'm getting error 1241 when enter following:
select deployment, device_serial_number action_archive (.....) group device_serial_number order 'date'
one method uses subquery. looks this:
select aa.* rom action_archive aa (.....) , `date` = (select max(aa2.date) action_archive aa2 . . . , aa2.device_serial_number = aa.device_serial_number );
Comments
Post a Comment