Jython 上的 Django 和 Oracle:打开的游标太多

发布于 2024-09-17 18:15:43 字数 241 浏览 0 评论 0原文

我在 Jython 和 Oracle 上运行 Django,经常得到著名的

“打开的游标太多”

错误。

使用 Python 和 cx_Oracle 驱动程序使用相同的代码永远不会发生这种情况。

zxJDBC 驱动程序是否有问题,或者也许有一种方法可以要求 Django 在我完成查询集时关闭游标?

谢谢,

斯蒂芬

I am running Django on Jython with Oracle and I often get the famous

"Too many open cursors"

error.

It never happens with the same code with Python and the cx_Oracle driver.

Is there something wrong with the zxJDBC driver or perhaps there is a way to ask Django to close the cursors when I am done with the querysets?

Thanks,

Stephane

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

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

发布评论

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

评论(1

一袭水袖舞倾城 2024-09-24 18:15:43

对我来说听起来像是一个结束问题。

我认为 with 关键字应该有助于关闭 Python 中的资源。我不知道连接处理是否是 Django 为您做的事情,或者您是否仍然需要在代码中管理它们,但这也许是解决这个问题的一种方法。

Sounds like a closing problem to me.

I think the with keyword is supposed to help with closing resources in Python. I don't know if connection handling is something that Django does for you or if you still have to manage them in your code, but perhaps that would be one way to address it.

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