Take the 2-minute tour ×

I have a large mysql table that I think might be using the wrong character set. If so I'll need to change it using


But since this is a very large table, I'd rather not run this command unless I have to. So my question is, how can I ask mysql what the character set is on a particular table?

I can call status in mysql to see the database's character set, but that doesn't necessarily mean all the tables have the same character set, right?

share|improve this question
add comment

2 Answers

up vote 2 down vote accepted

Try:show create table my_table;

share|improve this answer
add comment

if your table uses wrong character set, this query will break the data.
so, it must be converted another way.
if you don't want to convert, the only proper way to get correct data (i.e. tell mysql not to recode it) is SET NAMES <table charset> query. but sorting and filtering wouldn't work
to see current charset you can use SHOW CREATE TABLE query

share|improve this answer
add comment

Your Answer


