Click to See Complete Forum and Search --> : Are mysql and mysqli exclusive?


wsanders
04-15-2008, 06:21 PM
I am trying to build 5.2.5 on a RHEL system with the RHEL Mysql4 rpms. It will work with --with-mysqli=/usr/bin/mysql_config but not with --with-mysql (It can't find libmysqlclient - I am posting another thread about that.)

Anyway, I am trying to get MediaWiki to work - the PHP I build with --with-mysqli doesn't seem to work, MediaWiki complains about not having a Mysql-capable PHP, so apparently there is a difference.

Is a PHP built with mysqli supposed to be backward compatible with an application looking for mysql?

Thanks,

--w

laserlight
04-15-2008, 07:13 PM
Is a PHP built with mysqli supposed to be backward compatible with an application looking for mysql?
They are two different PHP extensions to access the same relational database management system software.

wsanders
04-15-2008, 07:23 PM
Thanks - I figured they were very different but unsure whether mysqli was backward-compatible. Love that OSS.

Odd that the configure script for PHP will let you specify mysql_config to --with-mysqli but not --with-mysql.

bradgrafelman
04-20-2008, 01:24 AM
Odd that the configure script for PHP will let you specify mysql_config to --with-mysqli but not --with-mysql.Actually, it's not odd at all - they are completely different extensions with completely different client libraries.

I would think that a popular software as a Wiki would know better than to use deprecated libraries such as the mysql extension, though...

NogDog
04-21-2008, 03:43 PM
Actually, it's not odd at all - they are completely different extensions with completely different client libraries.

I would think that a popular software as a Wiki would know better than to use deprecated libraries such as the mysql extension, though...
Ideally it would use something like PEAR MDB[2] or PDO in order to support many different databases/interfaces. :)