Thom
Thom

Reputation: 621

MySQL DESCRIBE INTO OUTFILE with windows command-prompt

I want to print the structure of a table fomr my database.
Now I use the mysql command:

DESCRIBE products;

But how do I get this output into a txt file? Like:

DESCRIBE products; > products.txt

Upvotes: 1

Views: 1645

Answers (1)

Sammitch
Sammitch

Reputation: 32272

mysql -u username -p -e 'DESCRIBE databasename.tablename' > output.txt

Upvotes: 2

Related Questions