11 Replies Latest reply on Jul 10, 2009 3:13 PM by 710436

    Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access

    710436
      Hi:

      Im new in occi for visual studio, im try to do some with occi, i dowloaded and installed vc9 libs and inc and instant client basic and sdk, but i can connect, can you help me?
      this is my history

      First-chance exception at 0x52902721 (GEOM.arx) in acad.exe: 0xC0000005: Access violation reading location 0xfeeefefe.
      Unhandled exception at 0x52902721 (GEOM.arx) in acad.exe: 0xC0000005: Access violation reading location 0xfeeefefe.

           
      'acad.exe': Loaded 'C:\app\Usser3\product\11.1.0\client_1\instantclient_11_1\vc9\oraocci11.dll'
      'acad.exe': Loaded 'C:\app\Usser3\product\11.1.0\client_1\oci.dll', Binary was not built with debug information.
      'acad.exe': Loaded 'C:\Windows\System32\msvcr71.dll'
      'acad.exe': Loaded 'C:\app\Usser3\product\11.1.0\client_1\oraociei11.dll', Binary was not built with debug information.
      'acad.exe': Loaded 'C:\Program Files\AutoCAD Map 3D 2010\dbghelp.dll'
      The thread 'Win32 Thread' (0x1718) has exited with code 0 (0x0).
      First-chance exception at 0x527b2721 (GEOM.arx) in acad.exe: 0xC0000005: Access violation reading location 0xfeeefefe.
      Unhandled exception at 0x527b2721 (GEOM.arx) in acad.exe: 0xC0000005: Access violation reading location 0xfeeefefe.


      oraociei11.dll     C:\app\Usser3\product\11.1.0\client_1\oraociei11.dll     N/A     N/A     Binary was not built with debug information.          436     OraOCIEI11.dll - 11.1.0.1.0
      oracore11.dll - 11.1.0.7.0 Product     01/10/2008 03:45 a.m.     1A480000-214C1000*     [5728] acad.exe: Native     
           oci.dll     C:\app\Usser3\product\11.1.0\client_1\oci.dll     N/A     N/A     Binary was not built with debug information.          434     11.1.0.1.0     01/10/2008 03:22 a.m.     19C70000-19CF2000*     [5728] acad.exe: Native     
           dbghelp.dll     C:\Program Files\AutoCAD Map 3D 2010\dbghelp.dll     N/A     N/A     Symbols not loaded.          437     6.10.0003.233 (debuggers(dbg).080908-1333)     08/09/2008 03:46 p.m.     520A0000-521BE000     [5728] acad.exe: Native     
           oraocci11.dll     C:\app\Usser3\product\11.1.0\client_1\instantclient_11_1\vc9\oraocci11.dll     N/A     N/A     Symbols not loaded.          433     11.1.0.6.0 Production     20/08/2008 03:45 a.m.     19BE0000-19C67000*     [5728] acad.exe: Native     
      acad.exe': Loaded 'C:\Users\Usser3\Documents\Visual Studio 2008\Projects\GEOM\Win32\Debug\GEOM.arx', Symbols loaded.
        • 1. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
          Mark Williams-Oracle
          Hello,

          I responded to your email as well, but posting my response here too.

          In the provided information I see:

          oracore11.dll - 11.1.0.7.0 <=== using Instant Client 11.1.0.7?

          and

          C:\app\Usser3\product\11.1.0\client_1\instantclient_11_1\vc9\oraocci11.dll <=== this does not make sense given the previous item

          as well as

          'acad.exe': Loaded 'C:\Windows\System32\msvcr71.dll' <=== runtime from Visual Studio .NET (2003)?

          However, at this time, there is no 11.1.0.7 version of OCCI certified with Visual Studio 2008 on 32-bit Windows:

          http://www.oracle.com/technology/tech/oci/occi/occidownloads.html

          So, what is "C:\app\Usser3\product\11.1.0\client_1\instantclient_11_1\vc9\oraocci11.dll" and how was this put here? What version is this?

          It looks like you are mixing multiple versions of libraries here which will not work with OCCI.

          Regards,

          Mark
          • 2. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
            710436
            Thanks

            so i need instant client 11.1.0.6 basic and sdk

            I will intall instant client 11.1.0.6 and

            I reinstall autocad

            and ill try

            and will see wish me luck
            • 3. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
              710436
              Hi Mark:

              I saw your blog, very helpful information to begginers i post the url for all that have a siimilar problems


              regards

              http://oradim.blogspot.com/2009/07/getting-started-with-occi-windows.html
              • 4. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
                710436
                hi mark i do the example but i have the next error
                error no se encontro msvcr90 (didnt find)

                status dll not found exited with code -1073741515
                • 5. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
                  Mark Williams-Oracle
                  Hi,

                  The msvcr90.dll file is part of the Microsoft C runtime libraries and should be found in a "Side by Side" folder on the system.

                  For example,

                  C:\>dir /s msvcr90.dll
                  Volume in drive C has no label.
                  Volume Serial Number is 48A0-8E76

                  Directory of C:\WINDOWS\WinSxS\x86_Microsoft.VC90.CRT_1fc8b3b9a1e18e3b_9.0.21022.8_x-ww_d08d0375

                  11/07/2007 02:19 AM 655,872 msvcr90.dll
                  1 File(s) 655,872 bytes

                  If you look at the oraocci11.dll.manifest file you will see this as "Microsoft.VC90.CRT". This file should be in the same directory as the oraocci11.dll file.

                  Make sure you have the proper version installed and accessible. As I said in my blog post, "One of the most crucial attributes of working with OCCI is that you must ensure that all of the components of the development environment and the runtime environment are supported combinations and correct versions. I can not emphasize this enough."

                  Regards,

                  Mark
                  • 6. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
                    710436
                    i did the same
                    i wrote the same command and i get this i think is the same as you so i get the rigth versions

                    Directorio de C:\Windows\winsxs\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.210
                    22.8_none_bcb86ed6ac711f91

                    01/07/2009 02:09 p.m. 655,872 msvcr90.dll
                    1 archivos 655,872 bytes

                    Directorio de C:\Windows\winsxs\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.307
                    29.1_none_e163563597edeada

                    01/07/2009 02:58 p.m. 655,872 msvcr90.dll
                    1 archivos 655,872 bytes

                    this the manifest


                    <?xml version='1.0' encoding='UTF-8' standalone='yes'?>
                    <assembly xmlns='urn:schemas-microsoft-com:asm.v1' manifestVersion='1.0'>
                    <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
                    <security>
                    <requestedPrivileges>
                    <requestedExecutionLevel level='asInvoker' uiAccess='false' />
                    </requestedPrivileges>
                    </security>
                    </trustInfo>
                    <dependency>
                    <dependentAssembly>
                    <assemblyIdentity type='win32' name='Microsoft.VC90.CRT' version='9.0.21022.8' processorArchitecture='x86' publicKeyToken='1fc8b3b9a1e18e3b' />
                    </dependentAssembly>
                    </dependency>
                    </assembly>

                    this is my path

                    PATH=C:\instantclient_11_1\vc9;C:\instantclient_11_1;C:\app\Usser3\product\11.1.
                    0\client_1;C:\app\Usser3\product\11.1.0\client_1\bin;C:\Windows\system32;C:\Wind
                    ows;C:\Windows\System32\Wbem;C:\Program Files\ATI Technologies\ATI.ACE\Core-Stat
                    ic;c:\Program Files\Microsoft SQL Server\90\Tools\binn\

                    and this is my error in vs

                    'prueba2_oci.exe': Loaded 'C:\Users\Usser3\Documents\Visual Studio 2008\Projects\prueba2_oci\Debug\prueba2_oci.exe', Symbols loaded.
                    'prueba2_oci.exe': Loaded 'C:\Windows\System32\ntdll.dll'
                    'prueba2_oci.exe': Loaded 'C:\Windows\System32\kernel32.dll'
                    'prueba2_oci.exe': Loaded 'C:\instantclient_11_1\vc9\oraocci11.dll'
                    'prueba2_oci.exe': Loaded 'C:\instantclient_11_1\oci.dll', Binary was not built with debug information.
                    'prueba2_oci.exe': Loaded 'C:\Windows\System32\msvcr71.dll'
                    'prueba2_oci.exe': Loaded 'C:\Windows\System32\advapi32.dll'
                    'prueba2_oci.exe': Loaded 'C:\Windows\System32\rpcrt4.dll'
                    'prueba2_oci.exe': Loaded 'C:\Windows\System32\psapi.dll'
                    Debugger:: An unhandled non-continuable STATUS_DLL_NOT_FOUND exception was thrown during process load
                    The program '[3532] prueba2_oci.exe: Native' has exited with code -1073741515 (0xc0000135).

                    and i said , download i think the rith versions but ???

                    and yes i have de manifest file in the same carpet of dll
                    • 7. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
                      Mark Williams-Oracle
                      Hi Luis,

                      It looks like you are working with a debug build:

                      'prueba2_oci.exe': Loaded 'C:\Users\Usser3\Documents\Visual Studio 2008\Projects\prueba2_oci\Debug\prueba2_oci.exe', Symbols loaded. <=== I see Debug in the path, so this looks like a debug build.

                      But then further down in your output I see this:

                      'prueba2_oci.exe': Loaded 'C:\instantclient_11_1\vc9\oraocci11.dll' <=== This is the release build of OCCI dll not the debug build.

                      You appear to be mixing debug and release libraries which will not work correctly.

                      This is in the following step in the blog post:

                      "Expand Configuration Properties node, expand Linker node, select Input item, enter "oraocci11d.lib" for a debug build or "oraocci11.lib" for a release build."

                      If you are creating a debug build you need to use oraocci11d.lib as input to the linker.

                      You use oraocci11.lib as input to the linker for the release build.

                      For your reference, this is what you should see in the output window in Visual Studio for the debug execution:
                      'OCCITest.exe': Loaded 'C:\Projects\OCCITest\Debug\OCCITest.exe', Symbols loaded.
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\ntdll.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\kernel32.dll'
                      'OCCITest.exe': Loaded 'C:\instantclient_11_1\vc9\oraocci11d.dll'  <=== Notice this is the debug version of the occi library (oraocci11d.dll not oraocci11.dll)
                      'OCCITest.exe': Loaded 'C:\instantclient_11_1\oci.dll', Binary was not built with debug information.
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\msvcr71.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\advapi32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\rpcrt4.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\secur32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\psapi.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\WinSxS\x86_Microsoft.VC90.DebugCRT_1fc8b3b9a1e18e3b_9.0.21022.8_x-ww_597c3456\msvcr90d.dll', Symbols loaded.
                      'OCCITest.exe': Loaded 'C:\WINDOWS\WinSxS\x86_Microsoft.VC90.DebugCRT_1fc8b3b9a1e18e3b_9.0.21022.8_x-ww_597c3456\msvcp90d.dll', Symbols loaded.
                      'OCCITest.exe': Loaded 'C:\instantclient_11_1\oraociei11.dll', Binary was not built with debug information.
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\ws2_32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\msvcrt.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\ws2help.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\shell32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\gdi32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\user32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\shlwapi.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\ole32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\oleaut32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\winmm.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\iphlpapi.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\crypt32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\msasn1.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\dbghelp.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\version.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\imm32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.5512_x-ww_35d4ce83\comctl32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\comctl32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\userenv.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\mswsock.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\dnsapi.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\winrnr.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\wldap32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\rasadhlp.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\hnetcfg.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\wshtcpip.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\netapi32.dll'
                      'OCCITest.exe': Unloaded 'C:\WINDOWS\system32\netapi32.dll'
                      'OCCITest.exe': Loaded 'C:\WINDOWS\system32\msctf.dll'
                      The program '[776] OCCITest.exe: Native' has exited with code 0 (0x0).
                      EDIT: Can you check to make sure you are linking the correct library and let us know if that works?

                      Regards,

                      Mark
                      • 8. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
                        710436
                        Hi mark

                        you are really helpful

                        again i have problems

                        now my errors are:

                        'prueba2_oci.exe': Loaded 'C:\Users\Usser3\Documents\Visual Studio 2008\Projects\prueba2_oci\Debug\prueba2_oci.exe', Symbols loaded.
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\ntdll.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\kernel32.dll'
                        'prueba2_oci.exe': Loaded 'C:\instantclient_11_1\vc9\oraocci11d.dll'
                        'prueba2_oci.exe': Loaded 'C:\app\Usser3\product\11.1.0\client_1\oci.dll', Binary was not built with debug information.
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\msvcr71.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\advapi32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\rpcrt4.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\psapi.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.vc90.debugcrt_1fc8b3b9a1e18e3b_9.0.30729.1_none_bb1f6aa1308c35eb\msvcr90d.dll', Symbols loaded.
                        'prueba2_oci.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.vc90.debugcrt_1fc8b3b9a1e18e3b_9.0.30729.1_none_bb1f6aa1308c35eb\msvcp90d.dll', Symbols loaded.
                        'prueba2_oci.exe': Loaded 'C:\app\Usser3\product\11.1.0\client_1\oraociei11.dll', Binary was not built with debug information.
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\ws2_32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\msvcrt.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\nsi.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\shell32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\gdi32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\user32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\shlwapi.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\ole32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\oleaut32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\winmm.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\oleacc.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\IPHLPAPI.DLL'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\dhcpcsvc.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\dnsapi.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\secur32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\winnsi.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\dhcpcsvc6.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\crypt32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\msasn1.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\userenv.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\dbghelp.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\imm32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\msctf.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\lpk.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\usp10.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.windows.common-controls_6595b64144ccf1df_6.0.6001.18000_none_5cdbaa5a083979cc\comctl32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\mswsock.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\wship6.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\nlaapi.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\NapiNSP.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\pnrpnsp.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\winrnr.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\Wldap32.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\rasadhlp.dll'
                        'prueba2_oci.exe': Loaded 'C:\Windows\System32\WSHTCPIP.DLL'
                        First-chance exception at 0x762e42eb in prueba2_oci.exe: Microsoft C++ exception: oracle::occi::SQLException at memory location 0x0018f574..
                        First-chance exception at 0x762e42eb in prueba2_oci.exe: Microsoft C++ exception: [rethrow] at memory location 0x00000000..
                        The program '[5544] prueba2_oci.exe: Native' has exited with code 1 (0x1).


                        Now im i really disappoiment but i try still

                        in fact i do this because i need to use some sdo_geometry types from oracle spatial, using the classes created with ott tool

                        but.......

                        regards
                        • 9. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
                          Mark Williams-Oracle
                          Hi Luis,

                          The OCCI methods can throw an exception of type SQLException (which is what has happened in your code) as well as STL exceptions.

                          I suggest you put in at least some basic error handling code. Maybe something similar this:
                          /*
                           * open connection with database -
                           * if an error occurs, simply catch it,
                           * display the message to the console,
                           * and then exit.
                           */
                          try
                          {
                            con = env->createConnection(user, passwd, db);
                          }
                          catch (SQLException& ex)
                          {
                            cout << ex.getMessage();
                          
                            exit(EXIT_FAILURE);
                          }
                          This is just an example of some basic error handling code. You may need something more complex (or not). You'll have to determine what you need in your code.

                          Here's some information about exception handling from the OCCI manual:

                          http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28390/relational.htm#i1012597

                          Regards,

                          Mark
                          • 10. Re: Windows Vista Home, Visual Studio 2008 sp1, Oracle 11g  Error Access
                            710436
                            Hi Mark

                            Thank Very Very Very much

                            Now i try to read geom fiel from oracle data bases


                            Regards