Re: OT: PHP 5.6 with ohs in FM11g on Win2k12 (x64)

  • From: Mladen Gogala <gogala.mladen@xxxxxxxxx>
  • To: Patrice sur GMail <patrice.boivin@xxxxxxxxx>
  • Date: Mon, 6 Feb 2017 23:19:57 -0500

On 02/06/2017 10:30 PM, Patrice sur GMail wrote:

sadly my developers want me to install PHP 5.6 with a 11g instantclient for backward compatibility...

Why would they need 11g instant client backward compatibility? The instant client for 12c can do everything that the instant client for 11g can do. The oci8 module can be linked with the instant client for 12c:

mgogala@umajor:~$ ldd /usr/lib/php/20151012/oci8.so

    linux-vdso.so.1 =>  (0x00007ffddf57f000)

libclntsh.so.12.1 => /usr/lib/instantclient_12_1/libclntsh.so.12.1 (0x00007f73ebc80000)

    libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f73eb891000)

libmql1.so => /usr/lib/instantclient_12_1/libmql1.so (0x00007f73eb61b000)

libipc1.so => /usr/lib/instantclient_12_1/libipc1.so (0x00007f73eb29d000)

libnnz12.so => /usr/lib/instantclient_12_1/libnnz12.so (0x00007f73eab93000)

    libons.so => /usr/lib/instantclient_12_1/libons.so (0x00007f73ea94c000)

    libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f73ea748000)

    libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f73ea43f000)

libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f73ea221000)

    libnsl.so.1 => /lib/x86_64-linux-gnu/libnsl.so.1 (0x00007f73ea008000)

    librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f73e9e00000)

    /lib64/ld-linux-x86-64.so.2 (0x00005560dfb9c000)

    libaio.so.1 => /lib/x86_64-linux-gnu/libaio.so.1 (0x00007f73e9bfc000)

libclntshcore.so.12.1 => /usr/lib/instantclient_12_1/libclntshcore.so.12.1 (0x00007f73e968a000)


And this is a Ubuntu system, which means that it doesn't support a full Oracle client:

phpinfo()

PHP Version => 7.0.13-0ubuntu0.16.10.1

System => Linux umajor 4.8.0-37-generic #39-Ubuntu SMP Thu Jan 26 02:27:07 UTC 2017 x86_64

Server API => Command Line Interface


I upgraded to PHP 7 specifically to be able to use oci8 2.1.3

mgogala@umajor:~$ pecl list Installed packages, channel pecl.php.net: ========================================= Package Version State oci8 2.1.3 stable

Here is the change log for oci8:

http://pecl.php.net/package-changelog.php?package=oci8

I want to be able to use implicit result sets, which are only available in 12c. Bugs with that were fully fixed only in 2.1.2. Implicit result sets, one of the features in 12c, work well with PHP 7. I haven't tested with Perl, but there hasn't been a new version for DBD::Oracle in a while. I don't think that Perl would work with the implicit result sets. However, I haven't tried, so I cannot tell for sure. I know that PHP 7 with oci8 2.1.3 does work with the implicit result set.
And there is no way you can force the 11g instant client to do implicit result sets. I would really recommend using 12c instant client and PHP 7. In case your developers are not aware of this new feature, here is an article about the implicit result sets from the guy who is curiously absent from the Oracle community:

http://tkyte.blogspot.com/2013/07/12c-implicit-result-sets.html


Regards


--
Mladen Gogala
Oracle DBA
Tel: (347) 321-1217

Other related posts: