0

I am using VC 6.0 and While compiling the code i am getting this error "error C2995: 'getVector' : template function has already been defined"

I have included the value of WIN32COMMON in the project Settings->C++ tab and in the category combo box as Preprocessor and in the preprocessordefinition text box as _WIN32COMMON and in the Addition include Libraries text box the complete path as "E:\app\user\product\11.1.0\db_1\OCI\include". in this include folder all the header files are present such as "occi.h".

I also tried with defining WIN32COMMON in my code Explicitly as follows

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

but then it started me giving 102 errors stating that 'DbManager undeclared identifier'.

i had also tried with including the addition libraries in the project settings->link tab-> and in category combobox i selected Input and in the Additional library path i gave the complete path for .lib files as "E:\app\user\product\11.1.0\db_1\OCI\lib\MSVC\vc8" but that also did'nt work. can somebody please guide me.Where iam lacking or i need to define some thing else in my code.

4

1 回答 1

0

MSVC++ 6.0 不支持函数模板的部分排序。尝试在您的代码中getVector()替换为。getVectorOfRefs()

Oracle 添加getVectorOfRefs()到 OCCI 以支持较旧的 Microsoft 编译器,例如 MSVC6,并建议使用它来代替getVector().

于 2012-07-03T19:47:47.650 回答