Mybat.batsqlplus -s a / a @ mydb @d: /a/mysql.sql
MySQL.SQLSET TIME OFF Echo Off Head Off - This line setting does not calculate time does not show SQL statement does not have a few lines, the name set PageSize 0 - Show a few lines to display a blank line or extra space Set trims on - Remove all spaces, the default length is not enough to fill the space set feedback off - does not display the number of lines that cannot be selected and the top line and the spool d: /a/aa1.txt - Output SELECT TNAME || '|' || TabType || '|' || Clusterid from Tab; - Content Spool Off - Stop Output Host D: /rar.exe A D: / A / AA1 D: /A/AA1.TXT - Compressed SPOOL D : /a/aa2.txtselect tname || '|' || || Clusterid from Tab; Spool Offhost D: / A/rar.exe A D: / AA2 D: / AA2 .txthost d: /a/rar.exe a d: / a / ysWj d: / a / *. TXTHOST D: /A/rar.exe e -o d: /a/yswj.rar * d: / a / A / - Decompression file, override Host Del D: /a/a/aa1.txt - Delete files if repeated
Test files are all in D: / A / Directory to have mysql.sql files and RAR.exe files