Use OCCI to access the Oracle database (4), occioracle
This article focuses on problem summary and will be updated in the future.
1. When executing Environment * env = Environment: createEnvironment ();, an exception is thrown. The code isORA-32104, but no error message
The reason is that the library used does not match. For example, if I use the 11 library, the environment is 10 Gb, so we need to put F: \ PProject \ oci \ 32 \ instantclient-basic-nt-11.2.0.4.0 \ instantclient_11_2 add to the environment variable path, and before the path of 10g.
The other is to use the DLL in F: \ PProject \ oci \ 32 \ occivc9win32-111060-132181 to overwrite the dll in F: \ PProject \ oci \ 32 \ instantclient-basic-nt-11.2.0.4.0 \ instantclient_11_2
You can understand this problem as follows:
At the time of development, I used the. h file in the instantclient-sdk-nt-11.2.0.4.0, used the. lib file in the occivc9win32-111060-132181,
Exe depends on the. dll file in the occivc9win32-111060-132181 and the oci. DLL in F: \ PProject \ OCI \ 32 \ instantclient-basic-nt-11.2.0.4.0 \ instantclient_11_2 (including other files, I .e. the environment)
2. There is no problem with running the compiled exe directly. However, if you start debugging through VS, the following error will be reported. I still don't know what the problem is. Please kindly advise me if you have encountered similar problems!
The reason has been found (when I configure the environment, especially when setting the PATH, VS has never been related, that is, the system settings read by VS are not updated, so VS thought that the problem was caused by the failure to find the relevant DLL. .)