1

I'm trying to connect to an Oracle XE database using sqlplus.exe with the following command:

CONNECT SYSTEM/password@

Yes that's right, the '@' symbol is the last letter of the password, and needs escaping. :(

Many thanks.

See also Oracle pl-sql escape character (for a ‘&’)

ian_scho
  • 113
  • 1
  • 1
  • 7

2 Answers2

7

Try like this. Connect SYSTEM/\"password@\"@tnsname

  • 1
    This has been already answered six years ago and your answer doesn't contribute anything new. – Sven Nov 15 '16 at 10:43
  • 3
    This new answer added the escaped double quotes and helped me out! – lanes Aug 21 '19 at 06:51
  • Helped me out too, oddly under a batch script _sqlplus_ is working with the command `sqlplus myuser/password!@dbhost`, but _impdp_ needs the ! escaping and quotes `impdp USERID=myuser/"password^!"@dbhost`. Go figure?! – mrswadge Oct 24 '19 at 16:00
5

Try

Connect SYSTEM/"password@"

or if you need to specify a TNSName

Connect SYSTEM/"password@"@tnsname
Falcon Momot
  • 24,975
  • 13
  • 61
  • 92
Gauthier
  • 66
  • 1
  • 2
  • 1
    I've just tried this with a password without the '@' and it works with the double quotes.... Thumbs up Gauthier and thanks! – ian_scho Nov 30 '10 at 15:43