![]() |
Quick SQL question
How would I go about sorting a query based upon only the first 3 characters in a column?
For instance, I have 3 records and my column has data such as: 1 "(T) - The 2nd thing i did" 2 "(E) - The 1st thing i did" 3 "(T) - Another Thing I did" I'm looking to sort based upon the letter within the (), so for above data, the first record returned should be # 2 if in ASC order, however I do NOT want any characters after the 3rd to affect the sort. Thanks hmm... following seems to be working: Code:
ORDER BY LEFT(title, 3) ASC |
All times are GMT. The time now is 08:58 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|