Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

connection to oracle database

Status
Not open for further replies.

baran121

Programmer
Sep 8, 2005
337
0
0
TR
Hi everybody,
in my project (visual basic 6.0) i generally use MS SQL SERVER.
first time i ll try to connect to ORACLE database.
i have tried to see about connection Oracle here , but i couldnt find enough information.
can you tell me please what is the steps of connection Oracle databes. what is the connection string.
i have below information :

USER_ID
PASSWORD
HOST
PORT
SERVICE_NAME

thank you.

 
I use something like this:

Code:
Dim Cn As ADODB.Connection

Set Cn = New ADODB.Connection
Cn.ConnectionString = "Driver={Microsoft ODBC for Oracle};" & _
            "SERVER=[blue]YoueServerHere[/blue]; UID=[blue]USER_ID[/blue]; PWD=[blue]PASSWORD[/blue]"
Cn.CursorLocation = adUseClient
Cn.Open

Have fun.

---- Andy

A bus station is where a bus stops. A train station is where a train stops. On my desk, I have a work station.
 
Or since this isn't really a VB question you might try an Oracle forum.
 
Can you just post the text of the error rather than a link. Not all of us are allowed to open external links like that

In order to understand recursion, you must first understand recursion.
 
I'd expect Oracle to supply a "client" package with a decent OLEDB Provider anyway. That old ODBC Driver is pretty obsolete.
 
In order to use ADODB, you need to add a reference to your VB6 Project:

Project - References - Microsoft ActiveX Data Object X.X Library

Have fun.

---- Andy

A bus station is where a bus stops. A train station is where a train stops. On my desk, I have a work station.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top