For example, you have a 32-bit application that uses the Microsoft OLE DB Provider for Jet. If you migrate the application to run in the 64-bit mode, the application cannot connect to the data source by using the Microsoft OLE DB Provider for Jet. This issue occurs because the application requires a 64-bit version of the Microsoft OLE DB Provider for Jet.

Note! Also a website is either an 32-bit or 64-bit application.

解决方案


If you run a program in a 64 bit environment and need to utilize jet to open an Access, Excel or text file there are several options to make this work.

  • Run the program in WoW64 mode (emulates 32-bit on 64 bit systems). This will make the 32 bit drivers work.
  • If the application is an web app hosted on IIS 7 you can choose to configure the web sites application pool to run in 32-bit mode.
  • With Office 2010, there are new drivers, the 2010 Office System Driver, which will be provided in both 32-bit and 64-bit versions. You can use these drivers to let your application connect to Access, Excel and text files in a 64 bit environment utilizing the new 64-bit drivers. The provider name is “Microsoft.ACE.OLEDB.12.0”. You don’t need to buy or install the Office suite, the components are available as a separate download. http://www.microsoft.com/downloads/details.aspx?FamilyID=C06B8369-60DD-4B64-A44B-84B371EDE16D&displaylang=en

总结


在数据库开发中,项目需要把EXCEL导入到64位的ORACLE数据库中,所以开发环境只能是64位的。我是利用第三种方式解决问题的。

参考http://www.connectionstrings.com/using-jet-in-64-bit-environments/

版权声明:本文为huahai原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://www.cnblogs.com/huahai/p/7270999.html