mysql - Formatting SHOW ENGINE INNODB STATUS outputs when “\n” are embedded as Text -


I am referring to

I have an output through this command:

mysql -e "Show Engine Inorodb Status" -U-P Database & gt; Mydumpfile.txt

However, I'm using instead of a real new line using any editor (low, VIM, KRITET).

How do I substitute with sed, awk or any other tool in shell?

You can use the following syntax of sed.

  sed -i -e 's | \\ n | \ N | G 'mydumpfile.txt  

If you want direct output directly from mysql, use the --table option in the mysql command.

  mysql --table -e "Show engine insodub status" -u -p database & gt; Mydumpfile.txt  

Comments

Popular posts from this blog

ios - How do I use CFArrayRef in Swift? -

eclipse plugin - Run java code error: Workspace is closed -

c - Error on building source code in VC 6 -