Microsoft
Software
Hardware
Network
Question : SORTING BY Column Names when Column Name is Numeric
Maybe this was bad design, but I have a table with some fields that has names that are simply numbers.
Here are some sample field in my STATISTICS table. ID, NAME, 1, 2, 3, 4
So I want to query for this data but I am getting an error when trying to sort by the field name. Or it sorts by the wrong one because it thinks it is the position of the field -> NOT the name of it.
Ie.
SELECT * FROM STATISTICS WHERE NAME LIKE "A%" ORDER BY 3;
This would actually sort by the "1" field.
In MS SQL Server I would put square brackets around the field name. Is there something similiar for MYSQL?
Thanks.
Answer : SORTING BY Column Names when Column Name is Numeric
use tablename.fieldname. for example STATISTICS.3
Random Solutions
DHCP database corruption
Office 2000 Afrikaans Dictionary
=countif(trim(a1:a100), "=red") does not work. How to fix this without vba?
Readonly access to SQL server 2008 database?
Missing DLL and SYSTEM.INI glitch.
how to download KERNEL32.DLL for Windows NT , and WCMDPA20.DLL for Widows 95
Shrinkfile and backup log with truncate only do not shrink log
Exchange 2003 cannot receive email but can send. OWA also does not work.
convert excel data sql data
Configuring Sybase ASE-15 for remote access