1

I have a very similar situation as described in below thread:

The 'OraOLEDB.Oracle' provider is not registered on the local machine, when working with a console application?

I have website application .Net 4.5, on windows server 2016 and vs2017 with configuration as 'Any CPU'. I have a service layer to connect to oracle database and get the data. It runs very fine and connect to oracle database.

Now, i have a console application to run a job and once this job completes, i need to update the database. I call service layer from console application to update the database. However this call fails, and gives me 'The 'OraOLEDB.Oracle' provider is not registered on the local machine' error.

Solution provided in above given post (i.e. compile your console app in x86) does work for me but i don't have this option (as i have dependency on some other things as well).

Do i have any other option to resolve this issue?

EDIT: I removed oracle client installed on machine and then reinstalled 64 bit ODAC but still same problem :(

Developer_LA
  • 75
  • 1
  • 4
  • 11
  • 2
    Most likely the console application is compiled as 32-bit. Can you change this? Other solution is to install 32-bit and 64-bit Oracle client, follow this instruction: https://stackoverflow.com/questions/24104210/badimageformatexception-this-will-occur-when-running-in-64-bit-mode-with-the-32#24120100 – Wernfried Domscheit Jan 26 '19 at 06:52
  • i tried both the options, i.e. installed 64 bit ODAC and then later 32 bit ODAC but none of these work. – Developer_LA Jan 28 '19 at 17:07
  • Really? Did you follow the instruction I provided? – Wernfried Domscheit Jan 28 '19 at 18:16
  • There was an issue with 64bit ODAC installation, A clean installation resolved the issue. Thanks WernFried. – Developer_LA Jan 30 '19 at 20:02

0 Answers0