[英]Oracle mutiple session for an application
I have a problem. 我有个问题。 Well, I have an VB6 app that connects to an oracle database.
好吧,我有一个连接到oracle数据库的VB6应用程序。 Normally it uses just one session to connect to the database, but after running an update query on a table, it opens another one, on wich it runs just one query :
SELECT VALUE FROM SYS.NLS_DATABASE_PARAMETERS WHERE PARAMETER = 'NLS_NCHAR_CHARACTERSET'
The update query is : 通常,它只使用一个会话连接到数据库,但是在表上运行更新查询后,它会打开另一个会话,直到它只运行一个查询:
SELECT VALUE FROM SYS.NLS_DATABASE_PARAMETERS WHERE PARAMETER = 'NLS_NCHAR_CHARACTERSET'
更新查询是:
UPDATE SYS_PASS set LAST_LOG = SYSDATE where ID = 'xxxx'
Any idee why this is happening, or how could i get rid of this extra session ? 任何想法为什么会这样,或者我如何摆脱这个额外的会议?
This extra SQL statement must be generated either by 此额外的SQL语句必须由
If you want know what for your database do select then ask about select (describe how you detected extra select etc), not about app, while people will not understand what problem do you have. 如果您想知道数据库的内容,请进行选择,然后询问选择(描述您如何检测到额外的选择等),而不是关于应用程序,尽管人们不会理解您遇到什么问题。
Your second query executes on the opened connection itself and not on any other connection. 您的第二个查询在打开的连接本身上执行,而不在任何其他连接上执行。
You might be seeing other connection because of connection pooling. 由于连接池,您可能会看到其他连接。 You can verify that by setting
Pooling = false
in the connection string. 您可以通过在连接字符串中设置
Pooling = false
来验证。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.