这个“多步 OLE DB”是什么? 错误?
我正在为班加罗尔最好的一款可怕的软件做一些工作。
它主要是用经典的 ASP/VbScript 编写的,但“移植”到了 ASP.NET,尽管 ASPX 页面中的大部分代码都是经典的 ASP 风格:(
当它尝试连接到我的本地数据库时,我收到此消息:
<多步 OLE DB 操作生成错误。如果可用,请检查每个 OLE DB 状态值。
Line 38: MasterConn = New ADODB.Connection()
Line 39: MasterConn.connectiontimeout = 10000
Line 40: MasterConn.Open(strDB)
有人知道此错误意味着什么吗?这个连接字符串:
PROVIDER=MSDASQL;DRIVER={SQL Server};Server=JONATHAN-PC\SQLEXPRESS\;DATABASE=NetTraining;Integrated Security=true
这是它最初使用的连接字符串,我只是将其重新指向我的数据库
更新:
问题是使用 ADO 的“集成安全性”,我更改为使用用户帐户。连接得很好。
I'm doing a little bit of work on a horrid piece of software built by Bangalores best.
It's written in mostly classic ASP/VbScript, but "ported" to ASP.NET, though most of the code is classic ASP style in the ASPX pages :(
I'm getting this message when it tries to connect to my local database:
Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.
Line 38: MasterConn = New ADODB.Connection()
Line 39: MasterConn.connectiontimeout = 10000
Line 40: MasterConn.Open(strDB)
Anybody have a clue what this error means? Its connecting to my local machine (running SQLEXPRESS) using this connection string:
PROVIDER=MSDASQL;DRIVER={SQL Server};Server=JONATHAN-PC\SQLEXPRESS\;DATABASE=NetTraining;Integrated Security=true
Which is the connection string that it was initially using, I just repointed it at my database.
UPDATE:
The issue was using "Integrated Security" with ADO. I changed to using a user account and it connected just fine.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
附带说明一下,connectionstrings.com 是一个很棒的网站,因此您不必记住所有连接字符串语法。
As a side note, connectionstrings.com is a great site so you don't have to remember all that connection string syntax.
我在尝试通过精彩的经典 ASP 连接到 MySQL 数据库时遇到了这个问题。 上面的解决方案并没有直接修复它,但我最终通过将ODBC驱动程序(从长期存在的3.51)更新到最新版本来解决它。 然后,我能够保留驱动程序行(并且不添加提供程序位),但我确实必须相应地更新连接字符串:
效果很好。 快乐哈喽。
I came across this problem when trying to connect to an MySQL database via the wonderful Classic ASP. The solutions above didn't fix it directly, but I resolved it in the end by updating the ODBC Driver (from the long standing 3.51) to the latest version. I was then able to leave the driver line in (and not add the Provider bit), but I did have to update the connection string accordingly to:
That worked fine. Happy chappy.
很久以前我在 ASP 工作中就遇到过这个问题。 我找到了这篇知识库文章,它对我有所帮助。 我希望它能解决你的问题。
http://support.microsoft.com/kb/269495
如果这不起作用并且一切检查完毕,那么它可能是你的连接字符串。 接下来我将尝试以下步骤:
删除:
将提供程序编辑为:
I ran into this a long time ago with working in ASP. I found this knowledge base article and it helped me out. I hope it solves your problem.
http://support.microsoft.com/kb/269495
If this doesn't work and everything checks out, then it is probably your connection string. I would try these steps next:
Remove:
Edit the Provider to this: