Fahim Wahid
Fahim Wahid

Reputation: 1

Connecting Oracle Database 11g Express Edition to Eclipse

I just installed Oracle Database 11g Express Edition.

In the Run SQL Command Line window I connected to database with username:SYSTEM and password:{password I selected during installation}

SQL>connect SYSTEM/{password}

Then I created a user with password as described in the documentation. After that, I am able to access the database i.e. creating and querying tables and info.

Now, I want opened latest Eclipse EE and opened a Database Development perspective. In the Data Source Explorer, I right clicked and selected New Connection. In the driver definition, I added the jar file ojdbc6.jar which is provided in the oracle installation.

I don't know what to fill in Host, Username, and Password. I tried several combinations, and still getting ping failed. Please help, I am trying it for 3 days now and got so frustrated.

Upvotes: 0

Views: 2597

Answers (1)

Aanya
Aanya

Reputation: 11

To check the host name -> ORACLE_HOME/server/network/admin open the tnsnames.ora file with oracle developer. You will see somethimg like this-

ADDRESS = (PROTOCOL = TCP)(HOST = hostname )(PORT = 1521

now in eclipse-> windows->preferences->data management-> connectivity -> driver definition there add oracle thin driver 11 and include necessary jars(u will find them in your \oraclehome->jdbc->lib ,then in properties in the connection url field include url with ur hostname you checked in tnsname.ora example -jdbc:oracle:thin:@hostname:1521:xe

I know, u are welcome.. i too spent 4 days in figuring this :)

Upvotes: 1

Related Questions