Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/oracle/10.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Powershell中的oracle instantclient 12c EZCONNECT提示输入密码_Oracle_Powershell_Instantclient - Fatal编程技术网

Powershell中的oracle instantclient 12c EZCONNECT提示输入密码

Powershell中的oracle instantclient 12c EZCONNECT提示输入密码,oracle,powershell,instantclient,Oracle,Powershell,Instantclient,我已在Windows 8.1上安装instantclient 12c x86 我可以从cmd.exe进行连接: 现在,当我在Powershell中尝试同样的方法时: 我想被提示输入密码。它不起作用 PS C:\Users\vagrant> sqlplus user@\"hostname:1521/SERVICE_NAME\" SQL*Plus: Release 12.1.0.2.0 Production on Thu Dec 3 06:30:12 2015 Copyright (c)

我已在Windows 8.1上安装instantclient 12c x86

我可以从cmd.exe进行连接:

现在,当我在Powershell中尝试同样的方法时:

我想被提示输入密码。它不起作用

PS C:\Users\vagrant> sqlplus user@\"hostname:1521/SERVICE_NAME\"

SQL*Plus: Release 12.1.0.2.0 Production on Thu Dec 3 06:30:12 2015

Copyright (c) 1982, 2014, Oracle.  All rights reserved.

ERROR:
ORA-12154: TNS:could not resolve the connect identifier specified


Enter user-name:
在这里我提供我的密码,它的工作

PS C:\Users\vagrant>sqlplus user/password@hostname:1521/SERVICE_NAME

SQL*Plus: Release 12.1.0.2.0 Production on Thu Dec 3 06:24:48 2015

Copyright (c) 1982, 2014, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options

SQL> 

使用Powershell中的sqlplus登录密码时,提示的正确语法是什么?

sqlplususer@hostname:1521/SERVICE\u NAME
?@PetSerAl ORA-12504:TNS:listener未在CONNECT\u数据中获得SERVICE\u NAME如何:
sqlplus--%user@“hostname:1521/SERVICE\u NAME\”
?为什么要添加
\“
?@PetSerAl符号:sqlplus--%user@\“hostname:1521/SERVICE_NAME\”不起作用。非常感谢。你能解释一下--%吗??
PS C:\Users\vagrant>sqlplus user/password@hostname:1521/SERVICE_NAME

SQL*Plus: Release 12.1.0.2.0 Production on Thu Dec 3 06:24:48 2015

Copyright (c) 1982, 2014, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options

SQL>