Connecting to Oracle - Please Help!

View: New views
2 Messages — Rating Filter:   Alert me  

Connecting to Oracle - Please Help!

by richmolj :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi - I am trying to connect to a remote Oracle server. I set up this connection fine in the "services" tab by selecting my Oracle driver, hit "connect using", etc. I can run SQL queries fine.

The problem is when I try to set up this connection in my Rails app. When I try to test the connection I get:

The driver encountered an error: java.sql.SQLRecoverableException: Io exception: Invalid connection string format, a valid format is: "host:port:sid"

BUT my string is in the correct format. From my YAML file:

development:
   adapter: oracle
   database: localhost:xxxx:xxxx
   username: xxxx
   password: xxxx

The big thing to note here is localhost even though it is a remote server - I am using Putty to set up a tunnel into it. As I said, this works fine using the "Services" tab in Netbeans, so I'm not sure if that's an issue. If it helps, my full connection string is in that tab is:

jdbc:oracle:thin:@localhost:xxxx:xxxx

And I've tried inserting that, and variations of that, numerous times.

Please help! I have been trying this for hours.

Re: Connecting to Oracle - Please Help!

by Erno Mononen :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Sorry, I can't help, but if you don't get any replies here you might
want to try asking on the JRuby users list (user@... --
you can subscribe at http://xircles.codehaus.org/projects/jruby/lists)

Erno


richmolj wrote:

> Hi - I am trying to connect to a remote Oracle server. I set up this
> connection fine in the "services" tab by selecting my Oracle driver, hit
> "connect using", etc. I can run SQL queries fine.
>
> The problem is when I try to set up this connection in my Rails app. When I
> try to test the connection I get:
>
> The driver encountered an error: java.sql.SQLRecoverableException: Io
> exception: Invalid connection string format, a valid format is:
> "host:port:sid"
>
> BUT my string is in the correct format. From my YAML file:
>
> development:
>    adapter: oracle
>    database: localhost:xxxx:xxxx
>    username: xxxx
>    password: xxxx
>
> The big thing to note here is localhost even though it is a remote server -
> I am using Putty to set up a tunnel into it. As I said, this works fine
> using the "Services" tab in Netbeans, so I'm not sure if that's an issue. If
> it helps, my full connection string is in that tab is:
>
> jdbc:oracle:thin:@localhost:xxxx:xxxx
>
> And I've tried inserting that, and variations of that, numerous times.
>
> Please help! I have been trying this for hours.
>
>  


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...

LightInTheBox - Buy quality products at wholesale price