I'm getting the following exception "ORA-24960: the attribute OCI_ATTR_USERNAME is greater than the maximum allowable length of 255" when using Environment:createConnection.
I'm using VisualC++ 8.0 and Oracle 10g R 10.2.0.


Below is the snippet of code that creates the problem:

#include <iostream>
#include<occi.h>
using namespace oracle:cci;
using namespace std;

try{

Environment *env = Environment::createEnvironment(Environment:EFAULT);
Connection *conn = env->createConnection ("scott","tiger");

}
catch(SQLException ex)
{
cout << ex.getMessage(); //throws 24960 error 
}

There's a typo in your code. I think you mean Environment::DEFAULT instead of Environment:EFAULT . I never heard of the second anyway ;)

Environment *env = Environment::createEnvironment(Environment:: DEFAULT ); i type but same problem