如何修改增加 timeout 時間

問題:
執行 Excel 資料匯入 SQL DB,當匯入 100 筆後 就會出現錯誤如下: 

Exception 

Error while executing JavaScript computed expression

Script interpreter error, line=10, col=7: Error while executing function '@JdbcGetConnection'

Error while creating connection

Time expired getting a connection (=10000 ms). Try again. 

回答:

因為寫入較多筆數進後端資料庫時,需要一個較大的暫存記憶空間來進行此程序。

請在程式中加入下面二行就可以解決:

'設一個暫存的的記憶空間 result.CacheLimit = DB_NONE 或 result.cacheLimit = 50
result.cacheLimit = 50
'批次大小
result.FetchBatchSize = 40