Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 481
  • Last Modified:

read an oracle database using vb.net

Dear Experts,

I would want to read an oracle database using my vb.net application.

I have tried the code below and got the error below.


 Dim oradb As String = "Data Source=(DESCRIPTION=" _
               + "(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=xxx-yyyy.tttt.tt.uu)(PORT=1521)))" _
               + "(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=bibp)));" _
               + "User Id=userid;Password=userpw;"
  Dim conn As New OracleConnection(oradb)

My computer is a 64 bit and I have been using PLSQL to access the oracle database.

Thank you for your help

Anthony



ttempt to load Oracle client libraries threw BadImageFormatException.  This problem will occur when running in 64 bit mode with the 32 bit Oracle client components installed.
0
Anthony Matovu
Asked:
Anthony Matovu
1 Solution
 
AndyAinscowCommented:
>>This problem will occur when running in 64 bit mode with the 32 bit Oracle client components installed.

Two choices.
Install 64 bit client components
Force your app to be a 32 bit version (you probably have it set to dynamically choose 32/64 bit depending on OP system).
0

Featured Post

Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now