Hi all,
I have an instance of a database running on remote machine. I can connect to it using SQL Developer or SQL Plus, for example
sqlplus.exe user/password@//myhostname:1521/servicename
but when I try to do the same from my app, I get the error:
ORA-12560: TNS:protocol adapter error when connecting to remote database
void start() {
Environment* env = Environment::createEnvironment(Environment::DEFAULT);
Connection* connection = env->createConnection (username, password, oracleConnectionString); // <-- SqlException ORA-12560, where oracleConnectionString is //myhostname:1521/servicename
Environment::terminateEnvironment(env);
}