문제

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
도움이 되었습니까?

해결책

mysql -u username -p -e 'DESCRIBE databasename.tablename' > output.txt
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top