the database is a mysql, data table with the following contents:
< table > < thead > < tr > < th > mysql > select * from test; < / th > < / tr > < / thead > < tbody > < tr > < td > id < / td > < td > tel < / td > < td > num < / td > < td > time < / td > < td > name < / td > < / tr > < tr > < td > 1 < / td > < td > 13011115652 < / td > < td > 5 < / td > < td > 12 < / td > < td > Liu Xiaoxiao < / td > < / tr > < tr > < td > 2 < / td > < td > 13021115651 < / td > < td > 5 < / td > < td > 12 < / td > < td > Wang Da < / td > < / tr > < tr > < td > 3 < / td > < td > 13036115653 < / td > < td > 5 < / td > < td > 12 < / td > < td > fruit < / td > < / tr > < tr > < td > 4 < / td > < td > 13046115654 < / td > < td > 5 < / td > < td > 12 < / td > < td > < / td > < / tr > < tr > < td > 5 < / td > < td > 13026115650 < / td > < td > 5 < / td > < td > 12 < / td > < td > < / td > < / tr > < tr > < td > 6 < / td > < td > 13026115655 < / td > < td > 5 < / td > < td > 12 < / td > < td > Zhang Xiao < / td > < / tr > < tr > < td > 7 < / td > < td > 13026115656 < / td > < td > 1 < / td > < td > 11 < / td > < td > about < / td > < / tr > < tr > < td > 8 < / td > < td > 13026115657 < / td > < td > 4 < / td > < td > 21 < / td > < td > < / td > < / tr > < tr > < td > 9 < / td > < td > 13026115658 < / td > < td > 6 < / td > < td > 31 < / td > < td > < / td > < / tr > < tr > < td > 10 < / td > < td > 13026115659 < / td > < td > 3 < / td > < td > 11 < / td > < td > < / td > < / tr > < tr > < td > 11 < / td > < td > 13626125651 < / td > < td > 9 < / td > < td > 22 < / td > < td > < / td > < / tr > < tr > < td > 12 < / td > < td > 13633325651 < / td > < td > 10 < / td > < td > 32 < / td > < td > < / td > < / tr > < tr > < td > 13 < / td > < td > 13833445652 < / td > < td > 24 < / td > < td > 120 < / td > < td > six routes < / td > < / tr > < tr > < td > 14 < / td > < td > 13833445644 < / td > < td > 24 < / td > < td > 120 < / td > < td > < / td > < / tr > < tr > < td > 15 < / td > < td > 13833445621 < / td > < td > 34 < / td > < td > 120 < / td > < td > < / td > < / tr > < tr > < td > 16 < / td > < td > 13833448999 < / td > < td > 14 < / td > < td > 110 < / td > < td > < / td > < / tr > < tr > < td > 17 < / td > < td > 13833448839 < / td > < td > 14 < / td > < td > 110 < / td > < td > Happy < / td > < / tr > < / tbody > < / table >17 rows in set (0.00 sec)
Thesql query statement needs to be sorted by the two fields num (number of calls) descending, name (contact), while paging displays 5 pieces of data per page.
specific sorting requirements: first show that name is not empty (these records whose name is not empty are sorted by num descending order), then show that the remaining name is empty (these name empty records are sorted according to num descending order), and show 5 records limit per page to complete
online and other bosses to solve, thank you very much!