Steynsk
asked on
Select only values that do not start with a uppercase character
Hi Expert,
I'd like to extract all values from a field that do not start with a uppercase character.
But extracting all values without uppercase characters would work as well.
Kind regards,
I'd like to extract all values from a field that do not start with a uppercase character.
But extracting all values without uppercase characters would work as well.
Kind regards,
ASKER
Hi n_swapnil,
Thanks for the quick responce. but the statement selects all records:
SELECT * FROM people WHERE BINARY UPPER(Left('givenname',1) = Left('givenname',1))
And instead of that it should only show the people with a givenname without uppercase characters.
thanks
Thanks for the quick responce. but the statement selects all records:
SELECT * FROM people WHERE BINARY UPPER(Left('givenname',1) = Left('givenname',1))
And instead of that it should only show the people with a givenname without uppercase characters.
thanks
Try this:
SELECT * FROM people WHERE BINARY LOWER(Left('givenname',1) = Left('givenname',1))
SELECT * FROM people WHERE BINARY LOWER(Left('givenname',1) = Left('givenname',1))
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
SELECT * FROM people where ((BINARY `givenname`) REGEXP '^[a-z]')
did the job.
Thanks
did the job.
Thanks
SELECT *
FROM Table1
WHERE BINARY UPPER(Left('Field1',1) = Left('Field1',1)
Just for reference:
http://dev.mysql.com/doc/refman/5.0/en/charset-binary-op.html