tamasgal
tamasgal

Reputation: 26269

Connecting to Oracle DB 11g with 10g client - syntax error

On a Ubunut machine, I use this command to connect to an Oracle 11g database with the 11g instant client:

sqlplus username/password@(DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = the.address.com)(PORT = theport)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = service.address.com)))

Which works fine… On Mac OS X Mountain Lion I could only get the instant client 10g (32bit version) running, which gives me this error when I try to connect using the same line:

-bash: syntax error near unexpected token `('

Did the syntax changed from 10g to 11g?

Upvotes: 0

Views: 1084

Answers (1)

Mat
Mat

Reputation: 206727

You need to put quotes around the connect string, parenthesis can be interpreted by your shell otherwise.

Something like:

sqlplus user/pass@"(DESCRIPTION...)"

Upvotes: 2

Related Questions