MySQL View table structure command
MySQL view table structure command, as follows:
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 note:
show databases;
Use database name;
Show tables;
The original unique index Ak_pas_name (pac_name) is in table Tb_webparamcounter,
Execute the following SQL 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 logic of the index is not correct, you need to add a field to go in, 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: Pc_id,pac_name,pac_value Three fields at this time are not foreign KEY
Otherwise, you must drop FOREIGN KEY First and then redo the previous step.
By the Way Oracle
SELECT * from V$database;
SELECT * from All_users;
SELECT * from User_tables;
MySQL View table structure command