开发者

Query fails when run via Visual Studio, works fine elsewhere

I receive this error:

[DB2/6000] SQL0952N Processing was cancelled due to an interrupt. SQLSTATE=57014

whenever I run a query via a visual studio project in vb.net. If I run the same query via Open Office Base, it takes a long time but it works. How do I go about troubleshooting whats causing th开发者_如何学Gois?


To add to @Tom H's answer. I had a timeout issue to. The only thing that worked for me is:

iDB2Command cmd = new iDB2Command(sqlStatement, conn);
cmd.CommandTimeout = 600;


That SQLSTATE code indicates a user interruption. It could be caused by a timeout. Check the timeout settings in your Visual Studio project for that particular connection and see if increasing it helps.

Since it's DB2, you might also need to take a look for the db2cli.ini file and increase the QUERYTIMEOUT INTERVAL there.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜