0
给这个UNIX脚本,计划批处理:ASE ISQL输出到文件,偶尔为空或空
isql -U$USR -S$SRVR -P$PWD -w2000 < $SCRIPTS/sample_report.sql > $TEMP_DIR/sample_report.tmp_1
sed 's/-\{3,\}//g' $TEMP_DIR/sample_report.tmp_1 > $TEMP_DIR/sample_report.htm_1
uuencode $TEMP_DIR/sample_report.htm_1 sample_report.xls > $TEMP_DIR/sample_report.mail_1
mailx -s "Daily Sample Report" [email protected] < $TEMP_DIR/sample_report.mail_1
有偶尔在那里附着在邮件中sample_report.xls,是空的情况下,零线。
我已经排除了以下几点:
- 不是命令处理超时 - 通过将-T30到isql,我得到的XLS和它所包含的错误,不空
- 没有SQL错误 - 通过在sql中强制出错,我得到了xls,它包含错误,不为空
- 不确定登录超时 - 通过添加-l1,它不超时,但我无法指定低于1的数字第二,所以我不能说
我不能重现这一点,因为我不知道原因。有没有其他人经历过这个或有办法解决这个问题?任何建议如何找到原因?它是unix还是Sybase的isql?