This content has been marked as final. Show 3 replies
You will find OCCI 10g as part of 10g client installation. But that does not work with VS2010. You need to download the 18.104.22.168 OCCI libraries that are compatible with VS2010 and use them with 22.214.171.124 client software.
You can use that above (126.96.36.199 client) to connect to a 10.2 database.
I have installed vc2008 express edi and oracle 10g express edition.I have written this code :
using oracle :: occi;
using namespace std;
environment = oracle::occi::Environment::createEnvironment(oracle::occi::Environment::DEFAULT);
con = environment->createConnection("gldbuser", "gldbuser", "MYDATABSE");
stmt = con->createStatement("select * from example");
res = stmt->executeQuery();
It giving me error
\connectivity.cpp(20) : error C2872: 'Environment' : ambiguous symbol
1> could be 'C:\Program Files\Microsoft Visual Studio 9.0\VC\include\occiControl.h(732) : oracle::occi::Environment'
1> or 'c:\windows\microsoft.net\framework\v2.0.50727\mscorlib.dll : System::Environment'
Please give me solution for that
Did you check if OCCI dlls in 10g XE are built using VS2008. If not you have to use the same version of VS used in building the OCCI dlls.
You can do dumpbin to know the dependency and the version from it.