SQLCmd 挂在复杂的批处理脚本上

发布于 2024-08-06 22:12:37 字数 229 浏览 10 评论 0原文

我的公司目前正在使用 sqlcmd 2005 进行部署,由于某些原因,某些 SQL 脚本即使没有错误,它也往往会挂起,如果从 Management Studio 运行,它会成功完成。

它往往会挂在具有多个 GO 语句和/或游标的复杂脚本上。

我所说的“挂起”是指在我使用任务管理器明确终止该进程之前,该进程将不会完成。

有其他人有过这种经历吗?有什么建议可以解决这个问题吗?

谢谢

My company is currently using the sqlcmd 2005 for deployment and for some reason on certain SQL scripts it tends to hang even though there are no errors, and if run from management studio it completes successfully.

It tends to hang on complex scripts that have multiple GO statements and or cursors.

By "hang" I mean the process will not complete until I explicitly kill it with Task Manager.

Has anybody else had this experience, and have any suggestions to work around this issue?

Thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

落墨 2024-08-13 22:12:37

SQLCMD 似乎不喜欢多个 select 语句。当我将它们注释掉时,它就不再挂起。

SQLCMD doesn't seem to like multiple select statements. When I comment them out it doesn't hang anymore.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文