I want to find all the records in a database that begin with "a", "b" etc and count the results.
Something like:
SELECT * FROM table WHERE word STARTS_WITH "a" (!)
I am sure this is trivial but I can't find the right WHERE clause to use.
Any help gratefully received.
David
[Solved] Searching for sub-strings
Moderator: General Moderators
[Solved] Searching for sub-strings
Last edited by davidtee1 on Sat Sep 03, 2005 11:37 am, edited 1 time in total.
Code: Select all
SELECT count(*) FROM `table` WHERE `field` LIKE 'a%'