473,839 Members | 1,395 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

If you connect to Oracle through .NET please help!

I need to connect to an Oracle database. I've never done it before. I
see that with framework 1.1 you had to download ODP.NET from Oracle's site
in order for the framework classes to even work. I tried that quickly, but
the file is 400 MB, and the the installation asks for all kinds of things in
order to install. Now I'm very confused.

a) Do you still need ODP.NET with framework 2.0?
b) Do you need to download and install other Oracle files, too?
c) Do the answers to the ODP.NET questions about service names and host
names even matter when I'm going to be using a connection string inside my
code? Is my connection string somehow tied to those answers?
d) Can you refer to the server's IP address in your connection string
instead of the server name?

I can't find any good articles about this, and so your help above is
appreciated.
Jun 22 '06 #1
9 2424
D

In fact you do it almost the same as with an SQLServer. But there are
differences. The guys who are the most busy with Oracle are in the
newsgroup.

Microsoft.publi c.dotnet.framew ork.adonet

Not that you are not welcome here, in this newsgroup are as well some active
dealing with that, but in the newsgroup I showed, are more and there are
AFAIK some changes for 2.0.

Cor
"D. Patrick" <re************ *****@thenotrea l.com> schreef in bericht
news:A3******** ***********@tor nado.socal.rr.c om...
I need to connect to an Oracle database. I've never done it before. I
see that with framework 1.1 you had to download ODP.NET from Oracle's site
in order for the framework classes to even work. I tried that quickly,
but
the file is 400 MB, and the the installation asks for all kinds of things
in
order to install. Now I'm very confused.

a) Do you still need ODP.NET with framework 2.0?
b) Do you need to download and install other Oracle files, too?
c) Do the answers to the ODP.NET questions about service names and host
names even matter when I'm going to be using a connection string inside my
code? Is my connection string somehow tied to those answers?
d) Can you refer to the server's IP address in your connection string
instead of the server name?

I can't find any good articles about this, and so your help above is
appreciated.

Jun 23 '06 #2
guy
you do not need the oracle ODP.NET, you can use the MS .NET framework one
look in the vs docs help:-
Oracle Databases
Connections
"D. Patrick" wrote:
I need to connect to an Oracle database. I've never done it before. I
see that with framework 1.1 you had to download ODP.NET from Oracle's site
in order for the framework classes to even work. I tried that quickly, but
the file is 400 MB, and the the installation asks for all kinds of things in
order to install. Now I'm very confused.

a) Do you still need ODP.NET with framework 2.0?
b) Do you need to download and install other Oracle files, too?
c) Do the answers to the ODP.NET questions about service names and host
names even matter when I'm going to be using a connection string inside my
code? Is my connection string somehow tied to those answers?
d) Can you refer to the server's IP address in your connection string
instead of the server name?

I can't find any good articles about this, and so your help above is
appreciated.

Jun 23 '06 #3
Hi,

..NET applications can connect to Oracle using:

- Native ADO.NET providers from Microsoft or from Oracle (ODP.NET). Notice
that Microsoft DOES provide a .NET provider for Oracle. The only thing is
that for .NET Framework 1.0 you had to download it from the web, it didn´t
ship with VS for lack of time.

- The ADO.NET Provider for OLEDB with any OLEDB provider for Oracle.
- The ADO.NET Provider for ODBC with any ODBC driver for Oracle.

So, using .NET 2.0. you have to evaluate the Microsoft .NET Framework
Provider for Oracle agains ODP.NET.

In both cases the Oracle client libraries are required. AFAIK, only
DataDirect Technologies provides Oracle drivers/providers that can connect
directly to Oracle using the TNS protocol instead of the client libraries.

About connection strings, etc. refer to the docs of your provider of choice.
Basically Oracle provides name resolution based on file (TNSNAMES.ORA) or
based on server directory. In some cases I think that you can use the server
name or IP and other info instead of the service alias.

--

Best regards,

Carlos J. Quintero

MZ-Tools: Productivity add-ins for Visual Studio
You can code, design and document much faster:
http://www.mztools.com

"D. Patrick" <re************ *****@thenotrea l.com> escribió en el mensaje
news:A3******** ***********@tor nado.socal.rr.c om...
I need to connect to an Oracle database. I've never done it before. I
see that with framework 1.1 you had to download ODP.NET from Oracle's site
in order for the framework classes to even work. I tried that quickly,
but
the file is 400 MB, and the the installation asks for all kinds of things
in
order to install. Now I'm very confused.

a) Do you still need ODP.NET with framework 2.0?
b) Do you need to download and install other Oracle files, too?
c) Do the answers to the ODP.NET questions about service names and host
names even matter when I'm going to be using a connection string inside my
code? Is my connection string somehow tied to those answers?
d) Can you refer to the server's IP address in your connection string
instead of the server name?

I can't find any good articles about this, and so your help above is
appreciated.

Jun 23 '06 #4
On Thu, 22 Jun 2006 23:53:04 GMT, "D. Patrick" <re************ *****@thenotrea l.com> wrote:

¤ I need to connect to an Oracle database. I've never done it before. I
¤ see that with framework 1.1 you had to download ODP.NET from Oracle's site
¤ in order for the framework classes to even work. I tried that quickly, but
¤ the file is 400 MB, and the the installation asks for all kinds of things in
¤ order to install. Now I'm very confused.
¤
¤ a) Do you still need ODP.NET with framework 2.0?

It was never required since Microsoft released their own .NET provider for Oracle. Oracle's ODP.NET
provider requires a minimum version of the 9i client.

¤ b) Do you need to download and install other Oracle files, too?

You need to install and configure the Oracle client software.

¤ c) Do the answers to the ODP.NET questions about service names and host
¤ names even matter when I'm going to be using a connection string inside my
¤ code? Is my connection string somehow tied to those answers?

Not sure how to answer this question. The information in your connection string will depend upon the
Oracle client software configuration. You can find a few examples at:

http://www.connectionstrings.com/

¤ d) Can you refer to the server's IP address in your connection string
¤ instead of the server name?

Oracle uses host names that resolve to an IP address. The host names are specified in the
tnsnames.ora configuration file and used in the connection string.
Paul
~~~~
Microsoft MVP (Visual Basic)
Jun 23 '06 #5

"Paul Clement" <Us************ ***********@sws pectrum.com> wrote in message
news:pi******** *************** *********@4ax.c om...
On Thu, 22 Jun 2006 23:53:04 GMT, "D. Patrick"
<re************ *****@thenotrea l.com> wrote:

¤ I need to connect to an Oracle database. I've never done it before.
I
¤ see that with framework 1.1 you had to download ODP.NET from Oracle's
site
¤ in order for the framework classes to even work. I tried that quickly,
but
¤ the file is 400 MB, and the the installation asks for all kinds of
things in
¤ order to install. Now I'm very confused.
¤
¤ a) Do you still need ODP.NET with framework 2.0?

It was never required since Microsoft released their own .NET provider for
Oracle. Oracle's ODP.NET
provider requires a minimum version of the 9i client.

¤ b) Do you need to download and install other Oracle files, too?

You need to install and configure the Oracle client software.

¤ c) Do the answers to the ODP.NET questions about service names and host
¤ names even matter when I'm going to be using a connection string inside
my
¤ code? Is my connection string somehow tied to those answers?

Not sure how to answer this question. The information in your connection
string will depend upon the
Oracle client software configuration. You can find a few examples at:

http://www.connectionstrings.com/

¤ d) Can you refer to the server's IP address in your connection string
¤ instead of the server name?

Oracle uses host names that resolve to an IP address. The host names are
specified in the
tnsnames.ora configuration file and used in the connection string.
Paul
~~~~
Microsoft MVP (Visual Basic)

<< [ODP.NET] was never required since Microsoft released their own .NET
provider for Oracle. Oracle's ODP.NET provider requires a minimum version of
the 9i client.>>

Are you saying that I can access Oracle without installing any Oracle
software? That was my goal, but it didn't work. I received an exception
saying I must at least have the Oracle 8.1 client softare installed. I was
using the System.Data.Ora cleClient classes in framework 1.1. When I
installed ODP.NET, that exception went away, but I still couldn't connect.

It seems that I must have some Oracle software installed (to use the
tnsnames.ora file), right? Although please prove me wrong.
Jun 23 '06 #6
"D. Patrick" <re************ *****@thenotrea l.com> wrote in message news:xK******** **********@torn ado.socal.rr.co m...

"Paul Clement" <Us************ ***********@sws pectrum.com> wrote in message
news:pi******** *************** *********@4ax.c om...
On Thu, 22 Jun 2006 23:53:04 GMT, "D. Patrick"
<re************ *****@thenotrea l.com> wrote:

¤ I need to connect to an Oracle database. I've never done it before.
I
¤ see that with framework 1.1 you had to download ODP.NET from Oracle's
site
¤ in order for the framework classes to even work. I tried that quickly,
but
¤ the file is 400 MB, and the the installation asks for all kinds of
things in
¤ order to install. Now I'm very confused.
¤
¤ a) Do you still need ODP.NET with framework 2.0?

It was never required since Microsoft released their own .NET provider for
Oracle. Oracle's ODP.NET
provider requires a minimum version of the 9i client.

¤ b) Do you need to download and install other Oracle files, too?

You need to install and configure the Oracle client software.

¤ c) Do the answers to the ODP.NET questions about service names and host
¤ names even matter when I'm going to be using a connection string inside
my
¤ code? Is my connection string somehow tied to those answers?

Not sure how to answer this question. The information in your connection
string will depend upon the
Oracle client software configuration. You can find a few examples at:

http://www.connectionstrings.com/

¤ d) Can you refer to the server's IP address in your connection string
¤ instead of the server name?

Oracle uses host names that resolve to an IP address. The host names are
specified in the
tnsnames.ora configuration file and used in the connection string.
Paul
~~~~
Microsoft MVP (Visual Basic)

<< [ODP.NET] was never required since Microsoft released their own .NET
provider for Oracle. Oracle's ODP.NET provider requires a minimum version of
the 9i client.>>

Are you saying that I can access Oracle without installing any Oracle
software? That was my goal, but it didn't work. I received an exception
saying I must at least have the Oracle 8.1 client softare installed. I was
using the System.Data.Ora cleClient classes in framework 1.1. When I
installed ODP.NET, that exception went away, but I still couldn't connect.

It seems that I must have some Oracle software installed (to use the
tnsnames.ora file), right? Although please prove me wrong.


In my experience, you will need to install the "Oracle Client Tools" on all PCs that will run your application. Once the Oracle
client tools are installed, you configure the TNSNames.ora file either manually or with the oracle provided SQL*NET configuration
utility. I find that it is better to skip the SQL*NET utility and copy the TNSNames.ora file from a single location and, thus,
insuring that the files are all the same across all PC's. In fact, in many of my apps I copy the current TNSNames file from a
network directory during initialization of the app. That way, any changes to the TNSNames.ora file are automatically distributed to
the local PC's.

I hope this helps.

--
Al Reid
Jun 23 '06 #7

"Al Reid" <ar*****@reidDA SHhome.com> wrote in message
news:eM******** *****@TK2MSFTNG P05.phx.gbl...
"D. Patrick" <re************ *****@thenotrea l.com> wrote in message
news:xK******** **********@torn ado.socal.rr.co m...

"Paul Clement" <Us************ ***********@sws pectrum.com> wrote in
message
news:pi******** *************** *********@4ax.c om...
> On Thu, 22 Jun 2006 23:53:04 GMT, "D. Patrick"
> <re************ *****@thenotrea l.com> wrote:
>
> ¤ I need to connect to an Oracle database. I've never done it before.
> I
> ¤ see that with framework 1.1 you had to download ODP.NET from Oracle's
> site
> ¤ in order for the framework classes to even work. I tried that
> quickly,
> but
> ¤ the file is 400 MB, and the the installation asks for all kinds of
> things in
> ¤ order to install. Now I'm very confused.
> ¤
> ¤ a) Do you still need ODP.NET with framework 2.0?
>
> It was never required since Microsoft released their own .NET provider
> for
> Oracle. Oracle's ODP.NET
> provider requires a minimum version of the 9i client.
>
> ¤ b) Do you need to download and install other Oracle files, too?
>
> You need to install and configure the Oracle client software.
>
> ¤ c) Do the answers to the ODP.NET questions about service names and
> host
> ¤ names even matter when I'm going to be using a connection string
> inside
> my
> ¤ code? Is my connection string somehow tied to those answers?
>
> Not sure how to answer this question. The information in your
> connection
> string will depend upon the
> Oracle client software configuration. You can find a few examples at:
>
> http://www.connectionstrings.com/
>
> ¤ d) Can you refer to the server's IP address in your connection string
> ¤ instead of the server name?
>
> Oracle uses host names that resolve to an IP address. The host names
> are
> specified in the
> tnsnames.ora configuration file and used in the connection string.
>
>
> Paul
> ~~~~
> Microsoft MVP (Visual Basic)

<< [ODP.NET] was never required since Microsoft released their own .NET
provider for Oracle. Oracle's ODP.NET provider requires a minimum version
of
the 9i client.>>

Are you saying that I can access Oracle without installing any Oracle
software? That was my goal, but it didn't work. I received an exception
saying I must at least have the Oracle 8.1 client softare installed. I
was
using the System.Data.Ora cleClient classes in framework 1.1. When I
installed ODP.NET, that exception went away, but I still couldn't
connect.

It seems that I must have some Oracle software installed (to use the
tnsnames.ora file), right? Although please prove me wrong.


In my experience, you will need to install the "Oracle Client Tools" on
all PCs that will run your application. Once the Oracle
client tools are installed, you configure the TNSNames.ora file either
manually or with the oracle provided SQL*NET configuration
utility. I find that it is better to skip the SQL*NET utility and copy
the TNSNames.ora file from a single location and, thus,
insuring that the files are all the same across all PC's. In fact, in
many of my apps I copy the current TNSNames file from a
network directory during initialization of the app. That way, any changes
to the TNSNames.ora file are automatically distributed to
the local PC's.

I hope this helps.

--
Al Reid


The problem is that the client tools is a 1.3 GB (when unzipped) chunk of
code. It seems so crazy to do all that when I just want simply connectivity
for some simple "SELECT __ FROM TABLE" calls to an oracle database.
Jun 23 '06 #8
"D. Patrick" <re************ *****@thenotrea l.com> wrote in message news:yx******** *********@torna do.socal.rr.com ...

"Al Reid" <ar*****@reidDA SHhome.com> wrote in message
news:eM******** *****@TK2MSFTNG P05.phx.gbl...
"D. Patrick" <re************ *****@thenotrea l.com> wrote in message
news:xK******** **********@torn ado.socal.rr.co m...


In my experience, you will need to install the "Oracle Client Tools" on
all PCs that will run your application. Once the Oracle
client tools are installed, you configure the TNSNames.ora file either
manually or with the oracle provided SQL*NET configuration
utility. I find that it is better to skip the SQL*NET utility and copy
the TNSNames.ora file from a single location and, thus,
insuring that the files are all the same across all PC's. In fact, in
many of my apps I copy the current TNSNames file from a
network directory during initialization of the app. That way, any changes
to the TNSNames.ora file are automatically distributed to
the local PC's.

I hope this helps.

--
Al Reid


The problem is that the client tools is a 1.3 GB (when unzipped) chunk of
code. It seems so crazy to do all that when I just want simply connectivity
for some simple "SELECT __ FROM TABLE" calls to an oracle database.


Well, as crazy as it may sound, It is required. On my machine, using the Administrative user option, it consumes 325MB.
Application user install is somewhere around 200MB. If you don't want to install Oracle client tools on the PC's then you need to
look into using building an n-tier solution using remoting or web services.

--
Al Reid
Jun 23 '06 #9
On Fri, 23 Jun 2006 15:26:21 GMT, "D. Patrick" <re************ *****@thenotrea l.com> wrote:
¤
¤ << [ODP.NET] was never required since Microsoft released their own .NET
¤ provider for Oracle. Oracle's ODP.NET provider requires a minimum version of
¤ the 9i client.>>
¤
¤ Are you saying that I can access Oracle without installing any Oracle
¤ software? That was my goal, but it didn't work. I received an exception
¤ saying I must at least have the Oracle 8.1 client softare installed. I was
¤ using the System.Data.Ora cleClient classes in framework 1.1. When I
¤ installed ODP.NET, that exception went away, but I still couldn't connect.
¤

No, the Oracle client software must be installed and configured. That is, unless you're using a
third-party library such as DataDirect. The ODP.NET library is a separate install.
Paul
~~~~
Microsoft MVP (Visual Basic)
Jun 23 '06 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
21255
by: Hari Om | last post by:
Cannot connect as Internal Hello, I am using IBM AIX 5.1L box for Oracle 9.2.0.1. I cannot connect as internal to my DB INstance - wonder why? Here is what is do: ------------------------------------------------------------------- $export ORACLE_SID=GATES
1
4824
by: DAVID | last post by:
Hello, With regards to the Connect dialog on Oracle forms 6i via which we can connect to Oracle database, should we use the same functionality on forms run time again? I mean, I want to make a window with three screen items for username, password and service name. And on run time after connecting to the database I use this window to reconnect to an other database. So when I give the appropriate information, I will connect to the
1
10718
by: CM | last post by:
Hi, when i want connect me in my BD with a JSP (with this simple code), this exception is throw. Thank's for ur help Mathieu CODE of my JSP ---------------------
4
5217
by: Ellen K. | last post by:
Hi all, Being that so far I didn't get an answer to my below problem on the Oracle newsgroup, I figured it couldn't hurt to try here. While at my current job I've been working with mostly SQL Server, now I need to connect to our Oracle Financials running on HP-UX. The Oracle DBA set me up as a user and installed the Oracle client on my box and I have the tnsnames file, but I still can't establish a connection to the database from my...
5
13221
by: jrefactors | last post by:
My machine is Windows XP with Oracle 9.2 Home; IIS and Oracle are in the same box. I have tried both Oracle OLEDB Provider and Microsoft ODBC For Oracle, but both not working. For Microsoft ODBC For Oracle approach, I added a data source in Oracle Data Source Administrator, in System DSN tab, I created a system data source named OracleDSN with Microsoft ODBC for Oracle.
8
14381
by: danbredy | last post by:
Hi, I'm attempting to connect to an Oracle database using SQL Server 2005 Express (OS is Windows XP Professional) and having absolutely no luck. Here is the information SQL Plus gives me about the database when I log in - Connected to: Oracle9i Enterprise Edition Release 9.2.0.6.0 - 64bit Production With the Partitioning, OLAP and Oracle Data Mining options
7
4369
by: D. Patrick | last post by:
I need to connect to an Oracle database. I've never done it before. I see that with framework 1.1 you had to download ODP.NET from Oracle's site in order for the framework classes to even work. I tried that quickly, but the file is 400 MB, and the the installation asks for all kinds of things in order to install. Now I'm very confused. a) Do you still need ODP.NET with framework 2.0? b) Do you need to download and install other...
0
1208
by: Francois Stander | last post by:
Hi, I am struggeling to connect to an Oracle db 10.2 through vb.net. Oracle client is installed on my maschine, Oracle.DataAccess in referenced in my app. this is how my code looks like: Dim oradb As String = "Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=57.24.110.z)(PORT=1521)))" _ + "(CONNECT_DATA=(SID = pegtest)))" _ + "User Id=xxx;Password=yyyy)" Dim conn As New...
15
6663
Zwoker
by: Zwoker | last post by:
Hi all, I am accessing data from an Oracle database via a connect string. I got into the situation where I wanted to write my SQL select statement to do a join between a local table sitting in my MS Access (2003) database, and an external Oracle table. But I realised I had no idea how to write the SQL. It appears that the whole SQL command gets passed to Oracle, not giving me any visibility to my local tables, is that correct? I know...
0
9856
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10914
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10597
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10656
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9434
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7834
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5684
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5872
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
3136
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.