Question

Is it possible to select all the tables from a database (not knowing their names) and displaying them? My friend has a mysql server but he doesn't have phpMyAdmin installed and he's begging me to transfer all his php-fusion accounts to his new WordPress blog. He doesn't understand a thing with mysql... Anyone got an idea?

Was it helpful?

Solution

Use the SHOW and DESCRIBE statements. That's all phpMyAdmin is doing in the code. Your SQL user should have privileges.

List all tables:

SHOW tables;

List table definition:

DESCRIBE table_name;

Check out MySQL for more details.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top