You are looking for CHAR_LENGTH()
to get the number of characters in a string.
For multi-byte charsets LENGTH()
will give you the number of bytes the string occupies, while CHAR_LENGTH()
will return the number of characters.
More Related Contents:
- What is better subquery vs literal on IN clause in mysql
- SQL query return data from multiple tables
- quick selection of a random row from a large table in mysql
- MySQL: is a SELECT statement case sensitive?
- MySQL SELECT only not null values
- Combine Multiple child rows into one row MYSQL
- MySQL SELECT increment counter
- MySQL select statement with CASE or IF ELSEIF? Not sure how to get the result
- How to get an age from a D.O.B field in MySQL?
- How does MySQL’s ORDER BY RAND() work?
- MySQL #1093 – You can’t specify target table ‘giveaways’ for update in FROM clause
- MySQL How do you INSERT INTO a table with a SELECT subquery returning multiple rows?
- MySQL INSERT INTO … VALUES and SELECT
- Mysql select distinct
- MySQL error 1241: Operand should contain 1 column(s)
- How to select one row randomly taking into account a weight?
- Compare only day and month with date field in mysql
- mysql select sum group by date
- MySQL – SQL_BIG_SELECTS
- MySQL INNER JOIN select only one row from second table
- MySQL Select Query – Get only first 10 characters of a value
- What is the default MySQL JOIN behaviour, INNER or OUTER?
- MySQL : retrieve a large select by chunks
- MySQL – insert data from another table merged with constants
- Insert data into table with result from another select query
- How to SELECT by MAX(date)?
- How to use Table output from stored MYSQL Procedure
- MySQL matching unicode characters with ascii version
- MySQL Select Multiple VALUES
- mySQL returns all rows when field=0