The docs don’t mention ORDER BY and I have had no luck phrasing this query:
SHOW FIELDS FROM `TB_Main` WHERE Type = 'mediumtext' OR Type = 'bit(1)' ORDER BY Field;
Do I have to do my ordering in my scripting?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can directly query the information schema tables instead. As the manual says:
You can apply an
ORDER BYclause to the first type of statement, since it is a normalSELECTcommand.Therefore, in place of your
SHOWcommand, you can do: