In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] says... > Hi, > > First, let me say many thanks to those who responded to my cron tab > question - it's working well now. And now for my next trick ;) > > I'm looking for more of an opinion here. I'm doing an alphabetical listing > of members for this site, I've done a general query of my MySQL table to > select all the members, but I was wondering if PHP could select only the > first character and display only those members who's name begins with an > 'A', 'B', 'C', etc? > > I know I can do a selective query in MySQL using the LEFT command - but > that would mean doing a query for each letter of the alphabet - is there a > better way, or shall I start querying away?
I guess it would be possible to do this with 'DISTINCT' - something like SELECT DISTINCT LEFT(1,1,field) FROM ..... Yes I know the syntax is probably wrong but I can't be hanged checking the docs :-) Cheers -- Quod subigo farinam $email =~ s/oz$/au/o; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php