Problems with occi on windows

From: Alexander Kuznetsov <Alexander.Kuznetsov_at_marshmc.com>
Date: 27 Aug 2002 09:03:31 -0700
Message-ID: <ac5bc7c1.0208270803.69590be9_at_posting.google.com>


Hi forum,
I'm having problems trying to run an OCCI example, occidml.cpp on Visual C++ 6.0 sp5

the file, after I somewhat twisted it. looks like this:



// oratest2.cpp : Defines the entry point for the console application. //

#include "stdafx.h"
#include <iostream>
#define WIN32COMMON
#include <occi.h>

using namespace oracle::occi;
using namespace std;

/////////////////////////////////////////
class occidml
{
  private:

  Environment *env;
  Connection *conn;
  Statement *stmt;
  public:

  occidml (string user, string passwd, string db)   {
    env = Environment::createEnvironment (Environment::DEFAULT);     conn = env->createConnection (user, passwd, db);   }
...
link returns this:
Linking...
oratest2.obj : error LNK2001: unresolved external symbol "public:

static class oracle::occi::Environment * __cdecl
oracle::occi::Environment::createEnvironment(enum
oracle::occi::Environment::Mode,void *,void * (__cdecl*)(void
*,unsigned int),void *
 (__cdecl*)(void *,void *,unsigned int),void (__cdecl*)(void *,void *))" (?createEnvironment_at_Environment_at_occi@oracle@@SAPAV123_at_W4Mode@123_at_PAXP6APAX1I@ZP6APAX11I_at_ZP6AX11@Z_at_Z) oratest2.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall oracle::occi::SQLException::~SQLException(void)" (??1SQLException_at_occi_at_oracle@@UAE_at_XZ) oratest2.obj : error LNK2001: unresolved external symbol "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall oracle::occi::SQLException::getMessage(void)const " (?getMessage_at_SQLExcepti
on_at_occi_at_oracle@@UBE?AV?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@XZ) oratest2.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall
oracle::occi::SQLException::getErrorCode(void)const " (?getErrorCode_at_SQLException_at_occi@oracle@@UBEHXZ) oratest2.obj : error LNK2001: unresolved external symbol "public: static void __cdecl oracle::occi::Environment::terminateEnvironment(class oracle::occi::Environment *)"
(?terminateEnvironment_at_Environment_at_occi@oracle@@SAXPAV123@@Z) Debug/oratest2.exe : fatal error LNK1120: 5 unresolved externals Error executing link.exe.

obviosly link is able to resolve almost all calls to OCCI, but not these

please explain me what I'm missing
Alexander Received on Tue Aug 27 2002 - 18:03:31 CEST

Original text of this message