Re: PHPLib and Pear merge

From: Date: Wed, 07 Mar 2001 16:50:50 +0000
Subject: Re: PHPLib and Pear merge
References: 1  Groups: php.pear 
Request: Send a blank email to php-pear+get-1640@lists.php.net to get a copy of this message
le 7/03/01 17:22, Chuck Hagenbuch à chuck@horde.org a écrit : > Quoting Paul Meagher <paul@datavore.com>: > >> Could you elaborate upon this limitation with a simple example of what you >> can't do with phplib and what you can do with PEAR:DB? > > If I want to nest sql queries, such that each inner query depends on a row of > the outer query, I can do this in pear, because running a new query doesn't > wipe away the current result set. But with phplib, I'd need to loop through > the > entire outer query, store the results somewhere, and then do all of the inner > queries. $db = new DB_xxx; $query1 = "select RRRR from XXXXX"; $db->query($query1); while ($db->next_record()) { $db2 = new DB_xxx; $query2 = "UPDATE XXXX SET XXXX WHERE XXXX='".$db->f("RRRR")."'"; $dbb->query($query2); } is this what you mean ? It works for me. Bertrand Mansion tapage.fr

« previous php.pear (#1640) next »