0
I have a mysql column that has a key
worthwhile MUL
, how to remove this setting from the command line?
My table has the following scheme:
+-----------------+--------------+------+-----+-------------------+-----------------------------+
| Field | Type | Null | Key | Default | Extra |
+-----------------+--------------+------+-----+-------------------+-----------------------------+
| imovel_id | int(11) | NO | PRI | NULL | auto_increment |
| user_id | int(11) | NO | | NULL | |
| img_dest | varchar(111) | YES | | NULL | |
| data_imob | timestamp | NO | | CURRENT_TIMESTAMP | on update CURRENT_TIMESTAMP |
| finalidade_imob | varchar(51) | NO | MUL | NULL | |
| status_imob | varchar(51) | NO | | NULL | |
| tipo_imob | varchar(255) | YES | | NULL | |
| uf_imob | varchar(51) | NO | MUL | NULL | |
| cidade_imob | varchar(255) | NO | | NULL | |
| bairro_imob | varchar(255) | YES | | NULL | |
| rua_imob | varchar(255) | YES | | NULL | |
| vaga_imob | varchar(255) | YES | | NULL | |
| dorms_imob | char(2) | YES | | NULL | |
| tamanho_imob | varchar(222) | YES | | NULL | |
| valor_imob | varchar(255) | YES | | 0 | |
| titulo_imob | varchar(255) | YES | | NULL | |
| descricao_imob | longtext | YES | | NULL | |
| carac_imob | varchar(255) | YES | | NULL | |
+-----------------+--------------+------+-----+-------------------+-----------------------------+
Thank you for your attention, I am new to mysql, which would be this name_index?
– MagicHat
the name of the index that the column has that would be your "key" that you specified above
– arllondias
I edited my question for you to have a basis of how is my table I would like to take the column setting
uf_imob
, I’m not getting through.– MagicHat
perform a
SHOW CREATE TABLE
, and check the Key name for the value, then run the above command. anything put in the answer theCREATE TABLE
hers please:– arllondias
the
MUL
only means that it is an index that is not Unique, it is multiple. its name you will be able to see in CREATE TABLE ;)– arllondias