Hi,
I want to insert long .log file into CLOB field of Oracle DB. The Log file will increase its size dynamically.
When i am trying to insert the file in CLOB i am getting ERROR:
ORA-01756: quoted string not properly terminated.
Please find below the code.
myLogCount=$(cat $LogFile | wc -c)
echo "myLogCount in Actual Program::::: $myLogCount"
if [ $myLogCount -gt 32767 ]
then
awk '{n=n+length+1}
n <= 32500
n > 32500 {n-=length;print substr($0,1,(32500-n));exit}
' $LogFile > $myTmpLog
echo "Log file too large to view, Please visit server to view complete log" >> $myTmpLog
myTmpLogCount=$(cat $myTmpLog | wc -c)
br_Update_Proxy_Job_Run_Status "$Comment" \
"$RunStatusId" \
"$WarningCount" \
"" \
"" \
"" \
"" \
"" \
"$RptTotalRejectedDF" \
"$myTmpLog" \
"$ProxyJobStatus"
else
br_Update_Proxy_Job_Run_Status "$Comment" \
"$RunStatusId" \
"$WarningCount" \
"" \
"" \
"" \
"" \
"" \
"$RptTotalRejectedDF" \
"$LogFile" \
"$ProxyJobStatus"
fi
Please help me with sample code or tell me where i am doing wrong.
Thanks-
Raj