The following query causes the company names to be returned sorted in alphabetical order but with lower case coming after upper case. i.e. Castrol coming after COMPMore. How do I make the ORDER BY ignore case and sort just by the letter? I've tried an UPPER(company) in the SELECT and while that works, it changes the company name to all caps for the rest of the application.
Thanks.
<CFQUERY NAME="companies" DATASOURCE="customers">
SELECT DISTINCT company
FROM database
WHERE (company LIKE 'C%') OR (company LIKE 'c%')
ORDER BY company
</CFQUERY>
Thanks.
<CFQUERY NAME="companies" DATASOURCE="customers">
SELECT DISTINCT company
FROM database
WHERE (company LIKE 'C%') OR (company LIKE 'c%')
ORDER BY company
</CFQUERY>