Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:63953 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 73460 invoked from network); 17 Nov 2012 17:16:31 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 17 Nov 2012 17:16:31 -0000 Authentication-Results: pb1.pair.com smtp.mail=keisial@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=keisial@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.212.182 as permitted sender) X-PHP-List-Original-Sender: keisial@gmail.com X-Host-Fingerprint: 209.85.212.182 mail-wi0-f182.google.com Received: from [209.85.212.182] ([209.85.212.182:55836] helo=mail-wi0-f182.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 88/29-08060-E66C7A05 for ; Sat, 17 Nov 2012 12:16:30 -0500 Received: by mail-wi0-f182.google.com with SMTP id cb5so2055840wib.11 for ; Sat, 17 Nov 2012 09:16:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=o8cnlyS0i/n2x9andnIEmh8JkbWiwIv/Pji+k/sKm4c=; b=EavRmmWjDtG4H7Yfvy46bsH+faJvc7piI9qeXgjBhSy2mVyRkH3j1S9zAFXliYHg0u uFlAHBLU9MjhjJkVUW4C+rx+jGWjdvUV8OUm4xKe/GxvEFVQG8LFM1I6ypMgXwLoy94n xDG4FnXqBKaFTVCe2Vli9ZIOfsN40xti3o2igt+nBlGZcV7Y1II6Z26LVvQuQX2tncLh AcZFVO6z6Zk/FpEccHjQ+lsHz2z9j56o4unzdmmUP3rSD+PYpL/fSd58hl8slnrTGH/f hjEXJn1+CMfSwSgw23My7Rmub/r6XKd0IitzFW0Mev1/ePg1n7nGPE7dm7fUn/10UXEb hoZA== Received: by 10.180.92.132 with SMTP id cm4mr2740333wib.12.1353172587766; Sat, 17 Nov 2012 09:16:27 -0800 (PST) Received: from [192.168.1.26] (80.Red-88-13-200.dynamicIP.rima-tde.net. [88.13.200.80]) by mx.google.com with ESMTPS id i6sm5758469wix.5.2012.11.17.09.16.25 (version=SSLv3 cipher=OTHER); Sat, 17 Nov 2012 09:16:27 -0800 (PST) Message-ID: <50A7C5FB.6070108@gmail.com> Date: Sat, 17 Nov 2012 18:14:35 +0100 User-Agent: Thunderbird MIME-Version: 1.0 To: Rasmus Lerdorf CC: PHP Developers Mailing List References: <50A30144.5070305@phpgangsta.de> <50A3BEC0.8030607@gmail.com> <50A54713.8090102@sugarcrm.com> <50A549EB.2020408@lerdorf.com> <50A5FB0C.1080602@lerdorf.com> <50A5FF83.1060706@lerdorf.com> <50A6088B.5010701@rotorised.com> <50A663EF.3020401@lerdorf.com> <50A7AB04.1080805@gmail.com> <50A7BA27.5040701@lerdorf.com> In-Reply-To: <50A7BA27.5040701@lerdorf.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] RFC: ext/mysql deprecation From: keisial@gmail.com (=?ISO-8859-1?Q?=C1ngel_Gonz=E1lez?=) On 17/11/12 17:24, Rasmus Lerdorf wrote: > Right, that is what I meant by focusing more on the carrot than the > stick. Many people, yourself included, don't realize the things they > would gain switching to mysqli. We need to do a better job with that and > perhaps even consider if there are other things we can do in the > extension to make it more attractive. Indeed. And it is something to do very carefully. Otherwise, it just looks like a "we vs them". > There is a good summary page here: > > http://php.net/manual/en/mysqlinfo.api.choosing.php > > As you can see there is more to it than just prepared statements. > Asynchronous queries, for example, is an extremely interesting feature. It's interesting, but in most cases you will want the results inmediatly. You can only take advantage of that if you know in advance your query, and you are doing anything else in the meantime. It has its uses, but that's not a complete killer (and makes code harder to follow). Also, it seems poorly documented, there is mysqli_reap_async_query listed in php.net but not how to make one :( A web search discovers a 2008 talk by Ulf, also points to http://blog.ulf-wendel.de/?p=201 (a 404) but no explanation "this is how you do it". A very hacky approach using curl appears much higher :( http://gonzalo123.com/2010/10/11/speed-up-php-scripts-with-asynchronous-database-queries/ > Being able to fire off your SQL query at the top of a page and then > instead of waiting around for the result continue building the page > until you get to the point where you need the DB result. Do you really expend that much time building your html that it makes a difference? > And chances are > that you will also eventually paint yourself into a corner with > ext/mysql if you ever need transactions or some of the newer features in > versions of MySQL beyond 5.1. BEGIN and COMMIT work quite well :) I don't know what mysql 5.1+ changes need client support. Maybe the new ways of password hashing.