I would like to ask where are the minor issues in writing PHP database operations? No records can be found as long as $ order value is assigned to the parameter.
But if this value is not given, five records can be found.
I think there are some syntax problems. please point your finger. thank you.
Reply to discussion (solution)
The order clause must be before the limit clause, and your code order is reversed, resulting in syntax errors. Generally, limit is the last component of an SQL statement.
By the way, you only find that the value cannot be found, which is actually an SQL statement parsing error. If you do not know how to debug and discover problems, the subsequent steps will be difficult to follow.
$ Q = 'Order by'. $ ORDER. 'desc ';
You can only use this method for one table .. So many fields are written to death...
In addition, the order by position is incorrect. first order by and then limit