Desc table name;
Show columns from table name;
Describe table name;
Show create table table name;
Use information_schema
Select * from columns where table_name = 'table name ';
By the way:
Show databases;
You can also
Use information_schema
Select table_schema, table_name from tables where table_schema = 'database name'
Use Database Name;
Show tables;
The original unique index ak_pas_name (pac_name) is in the tb_webparamcounter table,
Run the following SQL statement to modify the index:
Alter table tb_webparamcounter drop index ak_pas_name;
Alter table tb_webparamcounter add unique ak_pas_name (pc_id, pac_name );
If you find that the index logic is incorrect, you need to add another field to execute
Alter table tb_webparamcounter drop index ak_pas_name;
Alter table tb_webparamcounter add unique ak_pas_name (pc_id, pac_name, pac_value );
Note: The pc_id, pac_name, and pac_value fields are not foreign keys.
Otherwise, you must first drop foreign key and then redo the previous step.
Retrieve column name data type Remarks
Select column_name, data_type, column_comment from information_schema.columns where table_name =?