SELECT `c`.`F_ID`, `c`.`F_Name` `Com_Name` FROM `tb_tded_team` `t` LEFT JOIN `tb_competition` `c` ON `t`.`F_Competition`=`c`.`F_ID` WHERE `F_Date` > '2019-11-13 09:00' AND `F_Date` < '2019-11-14 09:00' GROUP BY `c`.`F_ID` ORDER BY `c`.`que`