Sorting a query in MySQL ignoring the word "The"
When you have a database of books or movies, some of the titles begin with "The." If you do a regular ORDER BY on the table, all the titles that start with "the" get clumped together. One option is running an unsorted query and sorting in PHP, but it would be better to sort at the database level. Here is a query I came up with to do that, using an IF function in MySQL!
continue reading...