M
Mark Brown
I'm trying to access an Oracle database vb.net. I found several examples.
I tried following each one, but I get the same error no matter what I try.
I don't really understand what the error means (I've never tried accessing
an Oracle database before). The error I get is:
ORA-12514: TNS:listener does not currently know of service requested in
connect descriptor
I installed the oracle dll and added it as reference (I get the same error
if I use the Oracle reference that came with VS2003.) I figure it's hitting
the database ok since if I change the name of the database it's connecting
to, I get an error that it couldn't resove the name. Here's the code I'm
using, pretty much straight from the example on Oracle's web site:
Dim con As OracleConnection = New OracleConnection
con.ConnectionString = "User ID=scott;Password=tiger;Data Source=oracledb;"
Try
con.Open()
Catch ex As Exception
tmp = ex.Message
End Try
Naturally, I'm using different user id, password and db name in my actual
code. The program errors on the con.Open() line.
Any ideas on where to look would be greatly appreciated.
Mark
I tried following each one, but I get the same error no matter what I try.
I don't really understand what the error means (I've never tried accessing
an Oracle database before). The error I get is:
ORA-12514: TNS:listener does not currently know of service requested in
connect descriptor
I installed the oracle dll and added it as reference (I get the same error
if I use the Oracle reference that came with VS2003.) I figure it's hitting
the database ok since if I change the name of the database it's connecting
to, I get an error that it couldn't resove the name. Here's the code I'm
using, pretty much straight from the example on Oracle's web site:
Dim con As OracleConnection = New OracleConnection
con.ConnectionString = "User ID=scott;Password=tiger;Data Source=oracledb;"
Try
con.Open()
Catch ex As Exception
tmp = ex.Message
End Try
Naturally, I'm using different user id, password and db name in my actual
code. The program errors on the con.Open() line.
Any ideas on where to look would be greatly appreciated.
Mark