Re: database stuff
| From: | mailling at bigfoot dot com | Date: | Mon, 30 Jul 2001 17:10:50 +0000 |
| Subject: | Re: database stuff | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-1151@lists.php.net to get a copy of this message | ||
ok, what I want basically is something similar to this:
//Valid only for mysql
function &getTables() {
return $this->getAll('SHOW TABLES');
}
function moveCursor($result, $rownum) {
return @mysql_data_seek($result, $rownum);} Do you think that something similar could be inserted in common? At 21:22 7/29/2001 -0300, you wrote:
Hello, "Tomas V.V.Cox" wrote: On Thursday 26 July 2001 20:51, mailling@bigfoot.com wrote:I would like to know if it is possible to add a method to move the pointer. Example, I would appreciate a method that use only: (ie. given for mysql) mysql_data_seek And don't mix this job with another one such as in fetchIntoI don't see how this could fit in the idea of a database abstraction layer. But always you can do what you want with the cursor as you have it stored as a property in the pear db result object: $result_object->result (before Stig beat me, I must say that this practise is unsopprted and unrecomended :) I think what he is asking is not a big deal but I just don't know if there could be a easy way to do it with PEAR-DB. Anyway, with Metabase you can always pass an arbitrary row number and with that do non-sequential access. It works compatibly with DBMS that only support non-sequential result set access, like Oracle and others. Metabase is smart enough to keep track of the numbers that are buffered. You may want to take a look how it is done by checking its documentation here: http://phpclasses.UpperDesign.com/browse.html/package/20 Manuel Lemos -- PEAR Development Mailing List (http://pear.php.net/) To unsubscribe, e-mail: pear-dev-unsubscribe@lists.php.net For additional commands, e-mail: pear-dev-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net