I have a countries table structured this way with an index in the iso2 column:

When executing a normal select query, the iso2 index works fine:

But when connecting to another table on iso2, this behaves very strangely:

First of all, he says NULL possible_keys, but then he still uses it? Then he also says 256 rows, which are the whole table. It works very slowly with large updates, so I can say that it does not use an index. What is the problem?
EDIT: Also, if I post the id column from the iso2 index (see the first image), then it will say that no index is used in the connection.
Additional Information: I am trying to normalize my data and use country_id instead of country . I was updating tables using country_id when I noticed that this was very slow. Several EXPLAIN made me find out that the index was not used. Maybe this has something to do with iso2 being char (2)?
I populated country_id as follows:
UPDATE leads LEFT JOIN countries on leads.country=countries.iso2 SET leads.country_id=countries.id
This query took almost 40 seconds for about 100 thousand rows in the leads table.
source share