SELECT value FROM table WHERE value=A ?
I thought this was going to be easy and thus never spend much time thinking about it until the second i had to implement it!!
I need to be able to sort by letters.
For example, i have 10.000 companys in the database and i want to have a query which will return ONLY those companys that start with a certain given letter.
But, how to get it done?
I wouldnt even know how to tell MySQL to only look at the first letter of each value...
Anyone had to do this before?
Help would be appreciated (or hints, tips ).
Best regards from Vienna at 03:07 in the morning *yawn*,
how about something like:
SELECT Company FROM $table WHERE Company='a%'
That would mean that all company's beginning with a will be shown.
I haven't really tested this but I remember using it before... It's either a % or a * I think...