2
我有這樣的場景:文件名,如SQL LOADER參數
在我的工作目錄,我有一個SH腳本,CTL文件和輸入文件, 當我嘗試啓動shell腳本與輸入參數(FILENAME.TXT):
mysh.sh filename.txt
我得到這個錯誤:
SQL*Loader-500: Unable to open file (filename.txt)
SQL*Loader-553: file not found
SQL*Loader-509: System error: No such file or directory
SQL*Loader-2026: the load was aborted because SQL Loader cannot continue.
注:我所有的對象(文件和目錄有777個權限)
如果我的完整路徑,輸入文件啓動shell腳本,一切工作正常
mysh.sh fullpathtofile/filename.txt
我的問題是:爲什麼當我僅輸入文件名作爲輸入參數時它不工作?我的SH文件的conent的
部分:
!/usr/bin/sh
sqlldr $USER/$PASSWD control=pathtofile data=$1 log=pathtofile bad=pathtofile
[編輯]你的問題,並在'mysh.sh'添加代碼 –
我做了rightnow,正如我上面所說,它工作正常,如果我插入輸入文件的完整路徑。提前致謝。 – Frank