Windows Oracle Data Access Components (MOSC)

MOSC Banner

Creating ODBC connection through CMD or Powershell

edited Aug 8, 2020 2:45AM in Windows Oracle Data Access Components (MOSC) 12 commentsAnswered

Hi, I have installed Oracle 19c in my system. I am trying to create ODBC connection through Command Prompt or PowerShell command.

PowerShell Command :

Add-OdbcDsn -DriverName "Oracle in OraDb19c_ADVA" -DsnType System -Name localhost -Platform 32-bit -SetPropertyValue @("Description=localhost", "tns=LOCALHOST") -passthru

I am able to add DSN localhost but TNS Service name is not getting set to LOCALHOST Sothat test connection is failing. Can anybody please suggest that what is the appropriate command to set the TNS Service name in above powershell command.

Also What is the command for command prompt to execute for adding localhost DSN .

Best Regards

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center