Re: Name for new function

From: Date: Mon, 17 Jul 2000 12:45:32 +0000
Subject: Re: Name for new function
References: 1 2 3 4  Groups: php.dev 
Request: Send a blank email to php-dev+get-24733@lists.php.net to get a copy of this message
Kristian Köhntopp wrote: > Derick Rethans wrote: > > It seems that the function written in C code is about 15-20% faster than the > > implementation in user-space PHP. I think it's significant enough. My plan is to > > commit the patch to cvs within a few days. (I have to do some tweaking at some > > places). > > Why did you write it as a PHP extension, and not as a MySQL extension? The MySQL TODO list says: Subqueries. select id from t where grp in (select grp from g where u > 100) This could be implemented in the MySQL library code (which I can read and understand), but I think that's definitly fast in cmoparision to implementatie into the server part of MySQL. As this item is almost 2 years on the TODO list, I don't think it will be implemented very soon, and I am not able to do it myself. > > > By doing what you did, you will generate hideously inefficient queries, > because they are run at the wrong side of the client-server chasm. > You will cement that wrongness by adding it to the PHP/MySQL extension > core. Other people will use it, and future scripts will depend on > it, making it necessary to keep your extension even after it has been > made obsolete by doing it the right way within the MySQL server. You're right, on the php-dev list Rasmus suggested to move this code to a seperate extension, which would collect more of this kind of code during time. This extension can than also be used with the PEAR database abstraction code. I hope this makes something clear about my intentions. Derick -- Derick Rethans JDI Media Solutions H.v.Tussenbroekstraat 1 6952 BL Dieren The Netherlands e-mail: d.rethans@jdimedia.nl http://www.jdimedia.nl/

« previous php.dev (#24733) next »