-
Connect without an entry in tnsname.ora
Each client has its own tnsname.ora on the local PC. Let say I want to connect to a new location instead from the tnsname. How can I connect?
I used 'sqlplus system/admin@172.20.21.15:1521rcl' where orcl is the service name. I got an error ORA-06401: NETCMN: invalid driver designator. Pls help on how to connect without a tnsname entry. Tks.
-
You can do it by specifing the connect string after the @ symbol
eg
Code:
sqlplus scott/tiger@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(Host=server_a)(Port=1521))(CONNECT_DATA=(SID=db_a)))
HTH
Jim
Oracle Certified Professional
"Build your reputation by helping other people build theirs."
"Sarcasm may be the lowest form of wit but its still funny"
Click HERE to vist my website!
-
Re: Connect without an entry in tnsname.ora
Originally posted by richyip
Each client has its own tnsname.ora on the local PC.
Why? Make one tnsnames.ora file, place it on a shared network drive, and set TNS_ADMIN environment variable (System Properties>Environment)to the shared directory location. Add sqlnet.ora there too if you are using it.
-
but you have to add the registry to point to the network beside system environment variable
-
That is so wrong, it is wronger than wrong.
-
can you explain why , please Stecal????
-
Without getting into all the high tech MCSE knowledge that is running around in my head, you do not need to do anything with the registry in this case. And for that matter, there is little you need to do with the registry on a routine basis. Adding an environment variable, either as a system variable or as a user variable, DOES NOT require any editing of the registry. You can see this for yourself. Add an environment variable named something odd or unique ("mytestenv") and set it to whatever. Close the system properties. THEN go look in the registry. Search for the variable. Did you have to set it? No. It is done by PFM (a form of Windows magic). Use regedit instead of rededt32 (the find key searches across the hives at the same time). If you don't want to wait on the search, go to HKEY_CURRENT_USER/Environment.
-
Originally posted by stecal
Without getting into all the high tech MCSE knowledge that is running around in my head, you do not need to do anything with the registry in this case. And for that matter, there is little you need to do with the registry on a routine basis. Adding an environment variable, either as a system variable or as a user variable, DOES NOT require any editing of the registry. You can see this for yourself. Add an environment variable named something odd or unique ("mytestenv") and set it to whatever. Close the system properties. THEN go look in the registry. Search for the variable. Did you have to set it? No. It is done by PFM (a form of Windows magic). Use regedit instead of rededt32 (the find key searches across the hives at the same time). If you don't want to wait on the search, go to HKEY_CURRENT_USER/Environment.
Do you have to reboot?
Jeff Hunter
-
Actually, this is the ONE time you don't have to reboot. An oversight on Microsoft's part, I'm sure.
-
jovery,
Yeah this is my connection:
sqlplus system/admin@172.20.21.15:1521:test
test is my service name and I got the error. So is there any problem with the connect string?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|