TerminateEnvironment error

Hello,
We have a library to handle the access to the Oracle DB. All works fine except that we get the following error when the terminateEnvironment is called:
*** glibc detected *** double free or corruption (!prev): 0x08778ae0 ***
./provTelnet.sh: line 4: 18814 Aborted ./cmdProvServer provTelnet_app
This is how we finalize the connection to the DB (in a method called finalize):
EXPORT void finalize(void* arg){
ORACLE_INFO* oi = (ORACLE_INFO*)arg;
oi->conn->terminateStatement(oi->stmt);
oi->env->terminateConnection (oi->conn);
Environment::terminateEnvironment (oi->env);
The real problem is that we get this error ONLY in the client machine, in our test lab we don't get this error. All of the version of OCCI, OS and DB is the same.
We are using:
OCCI: I get the last files from here http://www.oracle.com/technology/tech/oci/occi/occidownloads.html
OCCI for gcc 3.4.3 (Linux), 10.2.0.2.0 release
OS: RedHat Linux AS 4.0
Any clue?

please check with what shared objects your application is linked with. If you are using gcc3.4.3 on RHEL4 with OCCI/gcc3.4.3 compatible libraries, you should see your application linked with libstdc++.so.6. Running 'ldd' on your application executable should show that. Try recompiling and relinking your executable.

Similar Messages

  • Get a ORA-32104 error: Debian Oracle10gR2 OCCI

    My code is very simple, and i got an exception when I was trying to execute the following code env = Environment::createEnvironment (Environment::OBJECT); I have also tried env = Environment::createEnvironment (); The result is exactly the same.
    The exception is "Error while trying to retrieve text for error ORA-32104"
    My host is Debian, gcc4.1.2, and I have got the new occi library. I am confused with the error.
    I compiler the code with gcc3.4.3, but got the same error.
    Thanks.
    using namespace oracle::occi;
    using namespace std;
    int
    main( int argc, char* argv[] )
         Environment *  env = NULL;
      // Open a connection to the database, then close it.
      int ret = 0;
      try
        env = Environment::createEnvironment(Environment::OBJECT);
        catch (SQLException ea)
         cerr << " Oracle10g: " << ea.what();
         ret = 1;
      Environment::terminateEnvironment(env);
      return 0;
    }Thanks in advance,
    summer

    Do you have the following set in your ENV
    ORACLE_HOME
    ORACLE_SID
    rgds

  • HELP:link error under redhat linux 9.0(oracle 9.2.0)

    i link the demo shipped with oracle 9.2.0,but failed.
    error message shows:
    /usr/bin/g++ -L/home/oracle/product/9.2.0/lib/ -L/home/oracle/product/9.2.0/rdbm
    s/lib/ -o occiproc occiproc.o -locci -lclntsh `cat /home/oracle/product/9.2.0/
    lib/sysliblist` -ldl -lm
    occiproc.o(.gcc_except_table+0x70): undefined reference to `typeinfo for oracle:
    :occi::SQLException'
    occiproc.o(.gcc_except_table+0x88): undefined reference to `typeinfo for oracle:
    :occi::SQLException'
    occiproc.o(.gnu.linkonce.t._ZN8occiprocC1ESsSsSs+0x14): In function `occiproc::o
    cciproc[in-charge](std::basic_string<char, std::char_traits<char>, std::allocato
    r<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char>
    , std::basic_string<char, std::char_traits<char>, std::allocator<char> >)':: undefined reference to `oracle::occi::Environment::createEnvironment(oracle::o
    cci::Environment::Mode, void*, void* (*)(void*, unsigned), void* (*)(void*, void
    *, unsigned), void (*)(void*, void*))'
    occiproc.o(.gnu.linkonce.t._ZN8occiprocD1Ev+0x2e): In function `occiproc::~occip
    roc [in-charge]()':
    : undefined reference to `oracle::occi::Environment::terminateEnvironment(oracle
    ::occi::Environment*)'
    collect2: ld returned 1 exit status

    OCCI 9.2 is not supported with gcc3.2. Please search this forum for more details.

  • OCCI Error -  ORA-32102: invalid OCI handle

    Hi,
    I'm completely new to OCCI and Linux and trying to run the simple OCCI program given in oracle site (http://www.oracle.com/technology/tech/oci/occi/occibasic.html) to connect a remote Oracle DB server.
    #include <iostream>
    #include <occi.h>
    using namespace std;
    using namespace oracle::occi;
    int main()
    Environment* env = Environment::createEnvironment();
    Connection* conn = env->createConnection("testdb", "testdb", "192.168.10.118:1521/ORADB"); // user, password, url
    Statement* stmt = conn->createStatement();
    stmt->setSQL("INSERT into FRUITS (fruit, amt) VALUES ('apple', 10)");
    stmt->executeUpdate();
    conn->terminateStatement(stmt);
    env->terminateConnection(conn);
    Environment::terminateEnvironment(env);
    return 0;
    When I try to run it after compilation it gives the following error.
    ORA-32102: invalid OCI handle
    The error should be in the line: Connection* conn = env->createConnection("testdb", "testdb", "192.168.10.118:1521/ORADB");
    I could track it by placing a cout<< there.
    Why this is and how can I handle this error? Please post your experience.
    Thanks

    Hi,
    I found the reason. It may due to the permission level of the user "testdb". When I tried with a different user it worked!
    Thanks

  • OCCI-getString error

    The following is a small console program written with Visual C++
    6.0 sp 4.
    The program has a crash when it tries to destruct the
    string variable fodt in the while loop.
    Is this a known bug or is there an error in the code ?
    Bertil Reppen
    #include "stdafx.h"
    #include <iostream>
    //#include <string.h>
    #include <occi.h>
    using namespace std;
    using namespace oracle::occi;
    int main(int argc, char* argv[])
         const string username = "BERTIL";
         const string password = "REPPXX";
         const string url = "aoye.apintdom.no";
    Environment *env = Environment::createEnvironment (
    Environment::DEFAULT);
    try
              Connection *conn = env->createConnection
    (username, password, url);
              string sqlQuery = "SELECT pasientnr1,to_char
    (FODSELSDATO,'dd-mm-yyyy') FROM pasient_nr";
              Statement *stmt = conn->createStatement
    (sqlQuery);
              ResultSet *rs = stmt->executeQuery ();
              while (rs->next ())
                   long pasno = rs->getInt(1);
                   string fodt = rs->getString(2);
              stmt->closeResultSet (rs);
              conn->terminateStatement (stmt);
              env->terminateConnection (conn);
    catch (SQLException ea)
    cout << ea.what();
              catch (exception &excp)
         cout << excp.what() << endl;
    Environment::terminateEnvironment (env);
         return 0;

    Israel,
    Most of these errors do indeed arise from missing/wrong
    compilation flags/defines. Check out OCCI samples and
    the "make.bat" files in your %ORACLE_HOME%\rdbms\demo directory
    for the correct flags, includes, and libraries. Here is an
    example,
    :occimake
    cl -GX -DWIN32COMMON -I. -I%ORACLE_HOME%\oci\include -I. -D_DLL -
    D_MT %1.cpp /link /LIBPATH:%ORACLE_HOME%\oci\lib\msvc oci.lib
    msvcrt.lib msvcprt.lib oraocci9.lib /nod:libc
    Regards,
    Geoff
    the problem also occurs on VC 6.0 without any service pack.
    pay attention that the following expression:
    typeid(rs->getString(1)
    leads to a compiler internal error (getXXX other than string
    works just fine !!!).
    this, along with some other testings i've conducted might
    indicate that oraocci9.lib has been compiled with stl (or just
    string) which differs from the version supplied with msvc.
    it also can result from missing/wrong compilation flags/defines.
    i'm still working on this.
    if anyone finds the answer PLEASE contact me !!!
    regards,
    Israel Kalush

  • Linking Error in OCCI

    hi Guys...
    please help me...
    i m new in c++ connectivity with Oracle using OCCI...
    following is my code which i wrote in Dev C++ using g++ compiler
    #include <occi.h>
    using namespace oracle::occi;
    int main() {
    Environment *env = Environment::createEnvironment();
    Environment::terminateEnvironment(env);
    return 0;
    Errors comming
    Compiler: Default compiler
    Executing g++.exe...
    g++.exe "C:\Dev-Cpp\bin\occ1.cpp" -o "C:\Dev-Cpp\bin\occ1.exe" -I"C:\Dev-Cpp\lib\gcc\mingw32\3.4.2\include" -I"C:\Dev-Cpp\include\c++\3.4.2\backward" -I"C:\Dev-Cpp\include\c++\3.4.2\mingw32" -I"C:\Dev-Cpp\include\c++\3.4.2" -I"C:\Dev-Cpp\include" -I"E:\instantclient" -I"E:\oracle\product\10.2.0\db_1\OCI\include" -L"C:\Dev-Cpp\lib" -L"E:\instantclient"
    C:\DOCUME~1\MANSI\LOCALS~1\Temp/cc4Gcaaa.o(.text+0x52):occ1.cpp: undefined reference to `oracle::occi::Environment::createEnvironment(oracle::occi::Environment::Mode, void*, void* (*)(void*, unsigned int), void* (*)(void*, void*, unsigned int), void (*)(void*, void*))'
    C:\DOCUME~1\MANSI\LOCALS~1\Temp/cc4Gcaaa.o(.text+0x60):occ1.cpp: undefined reference to `oracle::occi::Environment::terminateEnvironment(oracle::occi::Environment*)'
    collect2: ld returned 1 exit status
    Execution terminated
    tell me where I am wrong???

    hi Mark,
    Thanks So much for replying...
    Actually I am totally new in C++ connectivity with oracle 10g database..
    could u please help me because tomorrow i have an interview on this...n i wnt to learn some basics of creating a connection
    it would be great if u can give me some steps on how to create a c++ program ( what compliers , header files,library files ..on which location they should be) that can connect to oracle 10g database.
    plz it very urgent
    i have done searching on google...but didn't get good tutorial on this...
    thanks
    mansi

  • Wierd error message while trying to connect...

    I''ve created a small OCCI application with Visual C++. I receive the following error in the code that tries to connect:
    ORA-24960: the attribute OCI_ATTR_PASSWORD is greater than the maximum allowable length of 255
    My password is less than 10 characters.
    Any ideas?
    Thank you,
    Jason
    Oracle Instant Client 10.2.0.1
    Windows XP Professional SP1
    Microsoft Visual C++ 6.0

    Code:
    #include "stdafx.h"
    #include <occi.h>
    #include <iostream>
    #include <string>
    using namespace oracle::occi;
    using namespace oracle::occi::aq;
    using namespace std;
    #pragma comment(lib, "oci")
    #pragma comment(lib, "oraocci10")
    int main(int argc, char* argv[])
        Environment *pEnv = NULL;
        try
            string user = "myuser";
            string password = "mypassword";
            string db = "mydb";
            pEnv = Environment::createEnvironment();
            Connection *pConnection = pEnv->createConnection(user, password, db);
            pEnv->terminateConnection(pConnection);
        catch(exception &str)
            cout << "Exeception : " << str.what() << endl;
        if(pEnv != NULL)
            Environment::terminateEnvironment(pEnv);
        return 0;
    Dependencies:
    Dump of file C:\instantclient_10_2\bin\oraocci10.dll
    File Type: DLL
    Image has the following dependencies:
    OCI.dll
    MSVCR71.dll
    MSVCP71.dll
    KERNEL32.dll
    Summary
    2000 .data
    C000 .data1
    29000 .rdata
    8000 .reloc
    1000 .rsrc
    78000 .text
    5000 .text1
    Compile/link: I have no idea. I am linking to oraocci10.lib and oci.lib. I can send a makefile if necessary.
    Why do you say the client can be only used in VS .Net? I have seen plenty of postings in the forum of people using Visual C++ 6.
    Thanks for your input,
    Jason

  • OCCI ERROR:  (ORA-24392 ) !!

    hello all:
    After my OCCI connection pool runs a moment.
    it Crash:
    Error number: 24392
    ORA-24392: &#27809;&#26377;&#19982;&#26381;&#21153;&#22120;&#21477;&#26564;&#30456;&#20851;&#30340;&#36830;&#25509;&#27744;
    ORA-24392: no connection pool to associate server handle
    follow is my occi connection pool source code.
    help me to find problem. thanks.
    class COcciPool
    public:
         Environment *env;
         ConnectionPool *connPool;
         //Connection *con;
         //Statement *stmt;
    private:
              string poolUserName;
              string poolPassword;
              string connectString;
              string username;
              string password;
              unsigned int maxConn;
              unsigned int minConn;
              unsigned int incrConn;
    public :
         * Constructor for the occipool test case.
         COcciPool ()
              //env = Environment::createEnvironment (Environment::DEFAULT);
              connPool = NULL;
              env = Environment::createEnvironment (Environment::THREADED_MUTEXED);
         }// end of constructor occipool ()
         * Destructor for the occipool test case.
         ~COcciPool ()
              if(connPool) freePool();
              Environment::terminateEnvironment (env);
    public:
         bool InitPool(char dbname,char uid,char *pwd,int min,int max,int incr);
         void freePool();
         Connection *getFreeConn();
         void freeConn(Connection *pcon);
    #include "occipool.h"
    #include "system.h"
    bool COcciPool::InitPool(char dbname,char uid,char *pwd,int min,int max,int incr)
         if( min>max || (min==0 && max==0) )
              printlog("Invalid Pool Parameter");
              return false;
         connPool = env->createConnectionPool(uid, pwd, dbname, min, max, incr);
    try
              if (connPool)
              printlog("SUCCESS - createConnectionPool");
              else
              printlog("FAILURE - createConnectionPool");
              /*con = connPool->createConnection (uid, pwd);
              if (con)
              cout << "SUCCESS - createConnection" << endl;
              else
              cout << "FAILURE - createConnection" << endl;*/
    }catch(SQLException ex)
              printlog("Exception thrown for createConnectionPool");
              printlog("Error number: %d", ex.getErrorCode());;
              printlog("%s",ex.getMessage().c_str());
              connPool = NULL;
              return false;
         connectString = dbname;
         poolUserName=uid;
         poolPassword=pwd;
         username = uid;
         password = pwd;
         maxConn = max;
         minConn = min;
         incrConn = incr;
         return true;
    void COcciPool::freePool()
         env->terminateConnectionPool (connPool);
    Connection *COcciPool::getFreeConn()
         Connection *pcon = NULL;
         if(connPool->getBusyConnections()>=maxConn)
              return NULL;
         try
              pcon = connPool->createConnection (username, password);
              if (!pcon)
              printlog("!!Warning:FAILURE - createConnection");
              /*cout << "SUCCESS - createConnection" << endl;
              else
              cout << "FAILURE - createConnection" << endl;*/
    }catch(SQLException ex)
              printlog("Exception thrown for createConnection");
              printlog("Error number: %d",ex.getErrorCode());
              printlog("%s",ex.getMessage().c_str());
              return NULL;
         return pcon;
    void COcciPool::freeConn(Connection *pcon)
         if(pcon)
              connPool->terminateConnection (pcon);
    Message was edited by:
    user470898

    When exactly do you get this error? Are you by any chance first terminating the connection pool and then trying to use/free a Connection?. Please post your coding showing the connection pool is being accessed.
    Thanks,
    Shankar

  • Linking error by using oracle11.1.0 OCCI in VS 2008 (Windows 64Bit)

    Hello *,
    I try to link a simple program in C++ (VS2008, Windows Professional 64 Bit) but I stiill get the LNK2001 error :
    error LNK2001: unresolved external symbol "public: static void __cdecl oracle::occi::Environment::terminateEnvironment...
    error LNK2001: unresolved external symbol "public: static class oracle::occi::Environment * __cdecl oracle::occi::Environment::createEnvironment
    I use the simple example from this thread Oracle 10g and OCCI in Visual Studio 2008
    but it doesn't work.
    Here my command line options in VS Project (Release):
    C/C++ Command Line: /O2 /Oi /GL /I "G:\OracleDB\product\11.1.0\db_1\OCI\include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_UNICODE" /D "UNICODE" /FD /EHsc /MD /Gy /Fo"Release\\" /Fd"Release\vc90.pdb" /W3 /nologo /c /Zi /TP /errorReport:prompt
    Linker:
    /OUT:"G:\WissArbeit\TestOracleCLI\Release\TestOracleCLI.exe" /INCREMENTAL:NO /NOLOGO /LIBPATH:"G:\Walther\Vesuch2\instantclient-basic-win-x86-64-11.1.0.7.0\instantclient_11_1\vc9" /MANIFEST /MANIFESTFILE:"Release\TestOracleCLI.exe.intermediate.manifest" /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /DEBUG /PDB:"G:\WissArbeit\TestOracleCLI\Release\TestOracleCLI.pdb" /SUBSYSTEM:CONSOLE /OPT:REF /OPT:ICF /LTCG /DYNAMICBASE /NXCOMPAT /MACHINE:X86 /ERRORREPORT:PROMPT oraocci11.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib
    PATH=G:\Walther\Vesuch2\instantclient-basic-win-x86-64-11.1.0.7.0\instantclient_11_1;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files (x86)\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\Java\jre6\bin;C:\Program Files (x86)\Tortoise SVN\bin;C:\Program Files (x86)\QuickTime\QTSystem\
    The folder ...instantclient-basic-win-x86-64-11.1.0.7.0\instantclient_11_1\vc9 contains
    oraocci11.dll
    oraocci11.dll.manifest
    oraocci11.lib
    oraocci11d.dll
    oraocci11d.dll.manifest
    oraocci11.lib
    downloaded from http://www.oracle.com/technology/tech/oci/occi/occidownloads.html
    Can somebody say what is wrong?
    Thanks
    Christina

    Hi Christina,
    This is what I did using Visual Studio 2008 Professional Edition on Windows Server 2008 64-Bit:
    I downloaded the Instant Client Basic and Instant Client Package - SDK for Windows (x64) from here:
    http://www.oracle.com/technology/software/tech/oci/instantclient/htdocs/winx64soft.html
    I then downloaded the OCCI for Visual C++9 (VS 2008)[Windows x64] from here:
    http://www.oracle.com/technology/tech/oci/occi/occidownloads.html
    I think these are the same downloads you used.
    1. I then extracted the Instant Client packages to C:\Temp which created the following directory:
    C:\Temp\instantclient_11_1
    2. The Instant Client SDK was extracted to C:\Temp as well into the following directory:
    C:\Temp\instantclient_11_1\sdk
    3. I extracted the OCCI package and then moved the libraries, dll files, and manifest files into C:\Temp\instantclient_11_1\sdk\lib\msvc\vc9
    4. I copied oraocci11.dll and oraocci11d.dll from C:\Temp\instantclient_11_1\sdk\lib\msvc\vc9 to C:\Temp\instantclient_11_1
    5. I removed oraocci11.lib from C:\Temp\instantclient_11_1\sdk\lib\msvc
    6. I added C:\Temp\instantclient_11_1 to the system path
    7. In Visual Studio 2008 I added the include and library paths as follows:
    Tools -> Options... -> Projects and Solutions -> VC++ Directories
    Platform: x64
    Show directories for:
    Include files -- here I added C:\Temp\instantclient_11_1\sdk\include (I removed all other Oracle include directories for the test)
    Library files -- here I added C:\Temp\instantclient_11_1\sdk\lib\msvc and C:\Temp\instantclient_11_1\sdk\lib\msvc\vc9 (I removed all other Oracle library directories for the test)
    8. Added oraocci11.lib to the linker in Project -> OCCITest Properties... -> Configuration Properties -> Linker -> Input -> Additional Dependencies -> oraocci11.lib
    9. I then built and executed the simple test you linked to above with no errors.
    Here's the build log for the release build:
    Build Log      Build started: Project: OCCITest, Configuration: Release|x64
    Command Lines      Creating temporary file "c:\My Projects\Test\CPP\OCCITest\x64\Release\RSP00000923843192.rsp" with contents
    /GL /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_UNICODE" /D "UNICODE" /FD /EHsc /MD /Fo"x64\Release\\" /Fd"x64\Release\vc90.pdb" /W3 /c /Zi /TP ".\OCCITest.cpp"
    Creating command line "cl.exe @"c:\My Projects\Test\CPP\OCCITest\x64\Release\RSP00000923843192.rsp" /nologo /errorReport:prompt"
    Creating temporary file "c:\My Projects\Test\CPP\OCCITest\x64\Release\RSP00000A23843192.rsp" with contents
    /OUT:"C:\My Projects\Test\CPP\OCCITest\x64\Release\OCCITest.exe" /INCREMENTAL:NO /MANIFEST /MANIFESTFILE:"x64\Release\OCCITest.exe.intermediate.manifest" /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /DEBUG /PDB:"c:\My Projects\Test\CPP\OCCITest\x64\Release\OCCITest.pdb" /SUBSYSTEM:CONSOLE /OPT:REF /OPT:ICF /LTCG /DYNAMICBASE:NO /MACHINE:X64 oraocci11.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib
    ".\x64\Release\OCCITest.obj"
    Creating command line "link.exe @"c:\My Projects\Test\CPP\OCCITest\x64\Release\RSP00000A23843192.rsp" /NOLOGO /ERRORREPORT:PROMPT"
    Creating temporary file "c:\My Projects\Test\CPP\OCCITest\x64\Release\RSP00000B23843192.rsp" with contents
    /outputresource:".\x64\Release\OCCITest.exe;#1" /manifest
    ".\x64\Release\OCCITest.exe.intermediate.manifest"
    Creating command line "mt.exe @"c:\My Projects\Test\CPP\OCCITest\x64\Release\RSP00000B23843192.rsp" /nologo"
    Creating temporary file "c:\My Projects\Test\CPP\OCCITest\x64\Release\BAT00000C23843192.bat" with contents
    @echo Manifest resource last updated at %TIME% on %DATE% > ".\x64\Release\mt.dep"
    Creating command line """c:\My Projects\Test\CPP\OCCITest\x64\Release\BAT00000C23843192.bat"""
    Output Window      Compiling...
    OCCITest.cpp
    Linking...
    Generating code
    Finished generating code
    Embedding manifest...
    Results      Build log was saved at "file://c:\My Projects\Test\CPP\OCCITest\x64\Release\BuildLog.htm"
    OCCITest - 0 error(s), 0 warning(s)And here is the output window results for executing the test from within Visual Studio:
    'OCCITest.exe': Loaded 'C:\My Projects\Test\CPP\OCCITest\x64\Release\OCCITest.exe', Symbols loaded.
    'OCCITest.exe': Loaded 'C:\Windows\System32\ntdll.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\kernel32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Temp\instantclient_11_1\oraocci11.dll'
    'OCCITest.exe': Loaded 'C:\Temp\instantclient_11_1\oci.dll', Binary was not built with debug information.
    'OCCITest.exe': Loaded 'C:\Windows\System32\msvcrt.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\advapi32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\rpcrt4.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\psapi.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\winsxs\amd64_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.1_none_99b61f5e8371c1d4\msvcr90.dll', Symbols loaded.
    'OCCITest.exe': Loaded 'C:\Windows\winsxs\amd64_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.1_none_99b61f5e8371c1d4\msvcp90.dll', Symbols loaded.
    'OCCITest.exe': Loaded 'C:\Temp\instantclient_11_1\oraociei11.dll', Binary was not built with debug information.
    'OCCITest.exe': Loaded 'C:\Windows\System32\ws2_32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\nsi.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\shell32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\gdi32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\user32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\shlwapi.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\ole32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\oleaut32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\winmm.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\oleacc.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\IPHLPAPI.DLL', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\dhcpcsvc.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\dnsapi.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\secur32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\winnsi.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\dhcpcsvc6.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\crypt32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\msasn1.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\userenv.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\dbghelp.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\imm32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\msctf.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\lpk.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\usp10.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\winsxs\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.6001.18000_none_152e7382f3bd50c6\comctl32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\mswsock.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\wship6.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\winrnr.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\Wldap32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\nlaapi.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\NapiNSP.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\rasadhlp.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\WSHTCPIP.DLL', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\netapi32.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Loaded 'C:\Windows\System32\cscapi.dll', Symbols loaded (source information stripped).
    'OCCITest.exe': Unloaded 'C:\Windows\System32\netapi32.dll'
    'OCCITest.exe': Unloaded 'C:\Windows\System32\cscapi.dll'
    The program '[3680] OCCITest.exe: Native' has exited with code 0 (0x0).I'm not sure if that is helpful at all, but I didn't have any errors.
    Some of the lines are really long... hopefully that doesn't cause too much difficulty in reading them.
    Regards,
    Mark

  • Run time error when select large field

    My code is:
    #define WIN32COMMON
    #include "stdio.h"
    #include <occi.h>
    #include <string>
    using namespace oracle::occi;
    using namespace std;
    int main()
         try
              //init env
              Environment *env = Environment::createEnvironment(Environment::THREADED_MUTEXED);
              //create connection
              Connection *conn = env->createConnection("system","password","to_o10g_db");
              //create sql statement
              Statement *stmt_insert =NULL;
              char intstr[6];
              string sql_str = string("insert into test_table_t values('name") + string("1' ,'value1')");
              printf("Execute 10000 times insert operation.\n");
              for(int i=0;i<10000;i++)
                   itoa(i, intstr, 10);
                   sql_str = string("insert into tang_test_t values('name")
                        + intstr
                             + string("','value")
                             + intstr
                             + string(" ')");
                   stmt_insert= conn->createStatement(sql_str);
                   stmt_insert->executeQuery();
                   conn->terminateStatement(stmt_insert);
              printf("Finished 10000 times insert operation.\n");
              Statement stmt = conn->createStatement("SELECT FROM tang_test_t");
              ResultSet *rs = stmt->executeQuery();
              //read record
              while(rs->next()) // when get 15 records ,raise error !!!!!!!!!!!!!! WHY????
                   printf("The Record is %s,%s.\n",rs->getString(1).c_str(),rs->getString(2).c_str());
              stmt->closeResultSet(rs);
              conn->terminateStatement(stmt);
              env->terminateConnection(conn);
              Environment::terminateEnvironment(env);
         catch(SQLException &e)
              printf(e.what());
         return 0;
    Who can help me? Thanks.

    What is the error '!!!!!!!!!'? Can you please be more clear? Thanks.

  • Unusual Error in Threaded Environment

    I get a weird error when running my application on a threaded mode. This error however occurs not always but once in a while and that too when I have around 20+ threads. When I have lesser number of threads this error does not occur at all or i could say very very rarely.
    any idea guys
    I am using 11g instant client and 10g database. and this is how my error message goes.
    *** glibc detected *** /home/bala/workspace/OracleTester/OracleTest/Debug/OracleTest: corrupted double-linked list: 0x0845a390 ***
    ======= Backtrace: =========
    /lib/tls/i686/cmov/libc.so.6[0xb61cc3f4]
    /lib/tls/i686/cmov/libc.so.6[0xb61ce207]
    /lib/tls/i686/cmov/libc.so.6(cfree+0x96)[0xb61ce456]
    /opt/oracle/instantclient/instantclient_11_1/libclntsh.so.11.1(sltsmxd+0x34)[0xb68d16b0]
    /opt/oracle/instantclient/instantclient_11_1/libclntsh.so.11.1(ltsmxd+0x37)[0xb6904633]
    /opt/oracle/instantclient/instantclient_11_1/libclntsh.so.11.1[0xb65e46a1]
    /opt/oracle/instantclient/instantclient_11_1/libclntsh.so.11.1(kpufhndl0+0x32a)[0xb65df82a]
    /opt/oracle/instantclient/instantclient_11_1/libclntsh.so.11.1(kpufhndl+0x20)[0xb65df4f6]
    /opt/oracle/instantclient/instantclient_11_1/libclntsh.so.11.1(kpuspsessionrelease+0x111d)[0xb6eed9e5]
    /opt/oracle/instantclient/instantclient_11_1/libclntsh.so.11.1(OCISessionRelease+0xa2)[0xb6d84086]
    and here is my code
    Environment* Genv1; // OCCI environment
    Connection* Gcon1; // OCCI connection
    int const MAX = 50;
    void openConcurrentConnections(void _tgtObject);
    int main(){
    int iRetVal;
    pthread_t thread[MAX];
    pthread_attr_t attr;
    void *status;
    Genv1 = Environment::createEnvironment(Environment::THREADED_MUTEXED);
    /* Initialize and set thread detached attribute */
    pthread_attr_init(&attr);
    pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_JOINABLE);
    for(int i =0 ;i<MAX;i++){
    iRetVal = pthread_create(&thread, &attr, openConcurrentConnections, (void *)i);
    if (iRetVal) {
    printf("ERROR; return code from pthread_create()is %d\n", iRetVal);
    exit(-1);
    /* Free attribute and wait for the other threads */
    pthread_attr_destroy(&attr);
    for(unsigned short int t=0; t< MAX; t++) {
    iRetVal = pthread_join(thread[t], &status);
    // delete all filereader pointers and set the variable to NULL
    if (iRetVal) {
    printf("ERROR; return code from pthread_join()is %d\n", iRetVal);
    exit(-1);
    printf("Main: completed join with thread %d having a status of %ld\n",t,(long)status);
    Genv1->terminateEnvironment(Genv1);
    printf("Main: program completed. Exiting.\n");
    pthread_exit(NULL);
    void openConcurrentConnections(void _tgtObject){
    Gcon1 = Genv1->createConnection("Ecologital","123","//192.168.1.11:1521/Neurologik");
    cout << "oracle connection OPENED" << endl;
    Genv1->terminateConnection(Gcon1);
    cout << "oracle connection CLOSED" << endl;
    pthread_exit((void*) _tgtObject);

    Hi,
    Have you tried running something like valgrind against this?
    Regards,
    Mark

  • Error LNK2028: unresolved token (0A00001F) "public: static class oracle....

    Hello,
    I am using MSVC C++ Express and Oracle XE. When I am building my C++ script I get the following errors:
    DbCheck.obj : error LNK2028: unresolved token (0A00001F) "public: static class oracle::occi::Environment * __clrcall oracle::occi::Environment::createEnvironment(enum oracle::occi::Environment::Mode,void *,void * (__clrcall*)(void *,unsigned int),void * (__clrcall*)(void *,void *,unsigned int),void (__clrcall*)(void *,void *))" (?createEnvironment@Environment@occi@oracle@@$$FSMPAV123@W4Mode@123@PAXP6MPAX1I@ZP6MPAX11I@ZP6MX11@Z@Z) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z)
    DbCheck.obj : error LNK2019: unresolved external symbol "public: static class oracle::occi::Environment * __clrcall oracle::occi::Environment::createEnvironment(enum oracle::occi::Environment::Mode,void *,void * (__clrcall*)(void *,unsigned int),void * (__clrcall*)(void *,void *,unsigned int),void (__clrcall*)(void *,void *))" (?createEnvironment@Environment@occi@oracle@@$$FSMPAV123@W4Mode@123@PAXP6MPAX1I@ZP6MPAX11I@ZP6MX11@Z@Z) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z)
    F:\Visual C++ Projects\DbCheck\Debug\DbCheck.exe : fatal error LNK1120: 2 unresolved externals
    I downloaded OCCI for Visual C++ 8 (Windows) Download (zip). but still get the error. I also linked oraocci10.lib and oraocci10d.lib but still nogo. I did it in the project property page under linker->input->additional dependencies. The configuration I choosed was:
    Configuration: Debug
    Platform: Win32
    Is there a way to determine what is missing or what is causing the error, does one of you know how to solve the problem?
    Thanks
    Rodger

    Could you try to create a CLR command line application and get that to run first ?
    This example here links and runs fine for me (it is a bit messy since I've been experimenting with my own mem leak problems, but it runs fine, you might want to change the select statement though)
    (The stdafx.h file only contains #pragma once, the TestRead class is there just to test mapping from std::string to System::String)
    #include "stdafx.h"
    #include <occi.h>
    using namespace System;
    using namespace std;
    using namespace oracle::occi;
    public ref class TestRead
    public:
         System::String^ GetStr(int index);
    internal:
         oracle::occi::ResultSet* m_resultSet;
    System::String^ TestRead::GetStr(int index)
         try
              return gcnew System::String(m_resultSet->getString(index).c_str());
         catch (const oracle::occi::SQLException& ex)
              throw gcnew System::Exception(gcnew System::String(ex.getMessage().c_str()));
         return "";
    int main(array<System::String ^> ^args)
    try
         oracle::occi::Environment *env = oracle::occi::Environment::createEnvironment((oracle::occi::Environment::Mode)(oracle::occi::Environment::OBJECT | oracle::occi::Environment::THREADED_MUTEXED));
    Connection *conn = env->createConnection("test","test","");
    try
    oracle::occi::Statement *stmt = conn->createStatement("Select site_addr From parcel");
    oracle::occi::ResultSet *rs = stmt->executeQuery();
         TestRead^ testread = gcnew TestRead();
         testread->m_resultSet = rs;
    //int MktId;
    string MktName;
    int rowno = 1;
    while (rs->next())
              System::String^ name = testread->GetStr(1);
    rowno++;
         // if (rowno > 100)
         //     break;
    stmt->closeResultSet(rs);
    conn->terminateStatement(stmt);
    catch (SQLException &ex)
    env->terminateConnection(conn);
    oracle::occi::Environment::terminateEnvironment(env);
    throw;//re-throw
    env->terminateConnection(conn);
    oracle::occi::Environment::terminateEnvironment(env);
    catch (SQLException &ex)
    Console::WriteLine(L"Hello World");
    return 0;
    }

  • OCCI Linker Errors

    Hi All,
    I'm new to Occi, I've tried running a sample program and I'm getting this Linker Error on VC 2008, I've copied oraocci11.lib to my project directory and I'm still getting this linker error, Can someone please help me out.
    My Environment is
    VC++ 2008
    Oracle 11i
    On Windows XP 32 Bit OS
    1>Compiling...
    1>stdafx.cpp
    1>Compiling...
    1>OracleConnectSample.cpp
    1>AssemblyInfo.cpp
    1>Generating Code...
    1>Compiling resources...
    1>Microsoft (R) Windows (R) Resource Compiler Version 6.1.6723.1
    1>Copyright (C) Microsoft Corporation. All rights reserved.
    1>Linking...
    1>OracleConnectSample.obj : error LNK2028: unresolved token (0A0002BD) "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall oracle::occi::SQLException::getMessage(void)const " (?getMessage@SQLException@occi@oracle@@$$FUBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ) referenced in function __catch$?main@@$$HYAHHPAPAD@Z$0
    1>OracleConnectSample.obj : error LNK2028: unresolved token (0A0002BF) "public: virtual __thiscall oracle::occi::SQLException::~SQLException(void)" (??1SQLException@occi@oracle@@$$FUAE@XZ) referenced in function __catch$?main@@$$HYAHHPAPAD@Z$0
    1>OracleConnectSample.obj : error LNK2028: unresolved token (0A0002C0) "public: static void __cdecl oracle::occi::Environment::terminateEnvironment(class oracle::occi::Environment *)" (?terminateEnvironment@Environment@occi@oracle@@$$FSAXPAV123@@Z) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2028: unresolved token (0A0002C4) "public: unsigned int __thiscall oracle::occi::Blob::length(void)const " (?length@Blob@occi@oracle@@$$FQBEIXZ) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2028: unresolved token (0A0002C5) "public: __thiscall oracle::occi::Blob::~Blob(void)" (??1Blob@occi@oracle@@$$FQAE@XZ) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2028: unresolved token (0A0002C7) "public: __thiscall oracle::occi::Blob::Blob(class oracle::occi::Blob const &)" (??0Blob@occi@oracle@@$$FQAE@ABV012@@Z) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2028: unresolved token (0A0002CC) "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@Environment@occi@oracle@@$$FSAPAV123@W4Mode@123@PAXP6APAX1I@ZP6APAX11I@ZP6AX11@Z@Z) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2019: unresolved external symbol "public: virtual __thiscall oracle::occi::SQLException::~SQLException(void)" (??1SQLException@occi@oracle@@$$FUAE@XZ) referenced in function __catch$?main@@$$HYAHHPAPAD@Z$0
    1>OracleConnectSample.obj : error LNK2019: 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@SQLException@occi@oracle@@$$FUBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ) referenced in function __catch$?main@@$$HYAHHPAPAD@Z$0
    1>OracleConnectSample.obj : error LNK2019: unresolved external symbol "public: static void __cdecl oracle::occi::Environment::terminateEnvironment(class oracle::occi::Environment *)" (?terminateEnvironment@Environment@occi@oracle@@$$FSAXPAV123@@Z) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2019: unresolved external symbol "public: unsigned int __thiscall oracle::occi::Blob::length(void)const " (?length@Blob@occi@oracle@@$$FQBEIXZ) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2019: unresolved external symbol "public: __thiscall oracle::occi::Blob::~Blob(void)" (??1Blob@occi@oracle@@$$FQAE@XZ) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2019: unresolved external symbol "public: __thiscall oracle::occi::Blob::Blob(class oracle::occi::Blob const &)" (??0Blob@occi@oracle@@$$FQAE@ABV012@@Z) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>OracleConnectSample.obj : error LNK2019: 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@Environment@occi@oracle@@$$FSAPAV123@W4Mode@123@PAXP6APAX1I@ZP6APAX11I@ZP6AX11@Z@Z) referenced in function "int __cdecl main(int,char * *)" (?main@@$$HYAHHPAPAD@Z)
    1>E:\Samples\OracleConnectSample\Debug\OracleConnectSample.exe : fatal error LNK1120: 14 unresolved externals
    Thanks
    Sunil

    Hi,
    It looks like you may not have added the occi library to the linker input in the project properties.
    Something like:
    Select Project –> <Name> Properties... from the menu (substitute your project name)
    Expand Configuration Properties node, expand Linker node, select Input item, enter "oraocci11d.lib" for a debug build or "oraocci11.lib" for a release build.
    Regards,
    Mark

  • Can Anybody Tell me  how to solve this Error (related OCCI)

    following Errors are Coming While Running...
    Programmmm
    int main()
    nvironment *env = Environment :: createEnvironment();
         cout << "Environment is creating" << endl;
    Connection *conn = env->createConnection( "test", "test" ,"10.116.64.98:1521/ORCL");
    cout << "Connecting to the database" << endl;     
    env->terminateConnection(conn);
    Environment::terminateEnvironment(env);
    return 1;
    Enviroment is Creating but not connecting to the Database.....
    my database Client is 10G
    VC++ 2005...
    I downloaded .dll and .lib files from below link
    http://www.oracle.com/technology/tech/oci/occi/occidownloads.html
    but same thing is working in VC++2003... But not in 2005..... Error is given below
    ERROR
    'sanju.exe': Loaded 'C:\WINNT\system32\mmdrv.dll', No symbols loaded.
    'sanju.exe': Unloaded 'C:\WINNT\system32\mmdrv.dll'
    First-chance exception at 0x7c59bc81 in sanju.exe: Microsoft C++ exception: oracle::occi::SQLException at memory location 0x0012fc34..
    First-chance exception at 0x7c59bc81 in sanju.exe: Microsoft C++ exception: [rethrow] at memory location 0x00000000..
    Unhandled exception at 0x7c59bc81 in sanju.exe: Microsoft C++ exception: oracle::occi::SQLException at memory location 0x0012fc34..
    The program '[1676] sanju.exe: Native' has exited with code -1073741510 (0xc000013a).
    can anybody help me plzzzzzzzzzz...
    cheers ,
    sanju
    }

    AFAIK, you can't mix and match vs2003 and vs2005 compiled libraries. I don't think 10g supports vs2005.
    11g does offer OCCI import libs (.lib) specifically for use with vs2005 in oci/lib/msvc/vc8.
    That's what I'm using successfully. 11g on Windows was recently released officially, give it a try for real vs2005 support. --DD                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Error in starting Adobe Bridge in Photoshop CS2

    I've just installed Photoshop CS2, however upon opening Adobe Bridge this error message appears " The application has failed to start because libagluc28.dll was not found. Reinstalling to application may fix the problem"
    I have reinstalled and click repair but to no avail
    I followed Adobe Support Knowledgebase solution and run CMD and this appears:
    c:Documents and Settings/Jesus M Ferraris>
    then i entered the command
    cacls c:\windows\installer /T /E /C /G administrators:F
    but an error message appears - 'cacls' is not recognized as an internal or external command, operable program or bathc file
    I also entered the next command
    cacls "c:\documents and setting\all users" /Y /E /C /G administrators:F
    still the same error as above appears, Please help, have I miss something or was my procedure correct...
    P4, 512ram, WXP 80gHD

    Very useful.
    Good Luck.
    My
    Si
    tes

Maybe you are looking for