orcl> host tnsping orcl TNS Ping Utility for 32-bit Windows: Version 22.214.171.124.0 - Production on 29-JAN-2013 08:46:04 Copyright (c) 1997, 2011, Oracle. All rights reserved. Used parameter files: c:\app\john\product\11.2.0\dbhome_1\network\admin\sqlnet.ora Used TNSNAMES adapter to resolve the alias Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = jwdell.bplc.co.za)(P OK (10 msec) orcl> select * from dual@orcl; D - X orcl>
TWO_TASK=REMCORP export TWO_TASK
moreajays wrote:Keep in mind that sqlplus still uses the same method to connect to the remote database. TWO_TASK changes client driver behaviour. It does not change how that connectivity works over TCP - that remains the same.
Setting TWO_TASK in your osuser profile can help you to connect directly to remote database from client without using sqlplus <username>@<TNS_Alias>/<pwd>
CoBy wrote:"You do not have to create the dblink in the remote database, you can create it in your own and then query:"
You do not have to create the dblink in the remote database, you can create it in your own and then query:
CREATE DATABASE LINK remotelink connect to username identified by password using 'identifier';
Select * from table@remotelink
I don't know any other possibilities for connecting to a remote database from an existing session.
972168 wrote:This makes no sense at all. You cannot do anything to or with a database when you are "outside the DB session".
Sir, this would help me in case I am outside the DB session, but not already inside a session of the local database.
All I want to do is to connect to the remote object. I do not have privileges to create objects in either my current session or the remote session. But I do have the select privilege on both.If you are connected to database "A" and want to query an object in database "B", you MUST have a database link defined in database "A". That's how oracle works. Period. End of Story. So why is it you cannot create a db_link, or have one created for you?