On 1 May 2005, at 11:17 AM, Dries Buytaert wrote:
On 01 May 2005, at 18:55, Gerhard Killesreiter wrote:
Generally, it will cause the same problem for me as switching to PHP 4.3 did. I run Debian and Debian stable does only provide MySQL 3. I haven't checked if there is a .deb for MySQL 4 on backports.org yet.
However, since our database abstraction layer is very modular, I could even continue to use mysql 3 if I wrote an appropriate include file and would be willing to live without some of the more advanced features.
The question is if we should ship a database.mysql3.inc file with Drupal 4.7 or not.
Well, the syntax for row-level locking is this:
SELECT * FROM cache WHERE cid = %s FOR UPDATE UPDATE cache SET ... WHERE ...
A "SELECT ... FOR UPDATE" reads the data and sets exclusive locks on each row it reads. AFAIK, this is valid ANSI SQL, yet it might give errors on either MySQL 3 or PostgreSQL. I don't have a MySQL 3 installation to test with these days but clearly, this is not something that is easily fixed using the database layer (unless you want to rewrite queries of course).
PostgreSQL 7.4 and later should support this: http://www.postgresql.org/docs/7.4/interactive/transaction-iso.html I haven't tried this, though. Djun