• Re: Link error?

    From A@21:1/5 to loud...@gmail.com on Thu Nov 23 10:46:34 2023
    Wouldn't You mind, if I rob Your car and all Your money tomorrow ?


    On Tuesday, July 9, 2013 at 4:49:15 PM UTC+3, loud...@gmail.com wrote:
    Hello all, I was trying to build a simple application using Oracle OCCI. Unfortunately this application stops working during connection to Oracle database. I guess it was because of linking but not sure. Can you please help me out?

    After showing 'Start, Create connection,Windows reports 'main.exe stopped working.'

    Code is:

    cout << "Start" << endl;

    env = Environment::createEnvironment(Environment::DEFAULT);

    try {
    cout << "Create connection" << endl;
    con = env->createConnection(user, password, db);
    cout << "Done" << endl;
    }
    catch (SQLException& ex) {
    cout << ex.getMessage();
    exit(EXIT_FAILURE);
    }

    Platform: Windows 7 64bit
    Oracle 11.2 64bit
    OCCI 11.2 64bit
    Visual Studio 2012 Express

    Compiling and linking output:
    cl -c -nologo -MT -W3 -WX -D_CRT_SECURE_NO_WARNINGS /EHsc -IC:\Users\hongliang.w
    ang\Downloads\instantclient_11_2\sdk\include -Fomain.obj main.cpp
    main.cpp
    link -nologo -release Ws2_32.lib main.obj C:\Users\hongliang.wang\Downloads\inst
    antclient_11_2\sdk\lib\msvc\oraocci11.lib C:\Users\hongliang.wang\Downloads\inst
    antclient_11_2\sdk\lib\msvc\oci.lib C:\Users\hongliang.wang\Downloads\instantcli
    ent_11_2\sdk\lib\msvc\ociw32.lib -out:main.exe

    Following dlls are in the same directory as main.exe
    2010-03-30 19:03 657,408 oci.dll
    2010-03-13 21:39 1,564,672 orannzsbb11.dll
    2010-03-30 18:22 1,314,304 oraocci11.dll
    2010-03-30 19:05 135,725,056 oraociei11.dll

    Any ideas? Thanks in advance!

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)