Re: Re: [metabase-dev] numRows in the oracle driver
| From: | Manuel Lemos | Date: | Tue, 11 Mar 2003 17:29:03 +0000 |
| Subject: | Re: Re: [metabase-dev] numRows in the oracle driver | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-14203@lists.php.net to get a copy of this message | ||
Hello,
On 03/11/2003 11:32 AM, Lukas Smith wrote:
It is the same thing but the problem is that until the result set is freed you will be occupying the memory for the result set buffer and the fetched array. Since allocated memory is not really freed until the process ends, the memory footprint remains high for large result sets.justIf people want to traverse the result set more than once they canhavedo just that by using one of the bulk fetching methods. Then theyWell I don't remember how this is handled in Metabase, but in MDB/DB the result set is freed after the bulk fetching. So once the entire result set is traversed you will only have the array.the data in an array with which they can do whatever they want.That is not the same thing. For database API like MySQL that already does their own buffering you are making the application spend more memory using bulk fetching.
I can do it although I have no big urgence for that. Anyway, the idea is to have an additional function to disable buffering before executing a query. For drivers like Oracle that have already buffering implemented, it is easy to support because all that needs to be done is to Unset previously buffered result set rows. For MySQL it requires some work to make it work as with Oracle and others. The greatest problem is that only one unbuffered query may be run at a given time until it is freed. -- Regards, Manuel LemosleftAh, you misunderstood me. I also want to make it possible for the programmer to set such a hint. Probably introducing a new option.I wanted to add this option before to Metabase, not because of Oracle but since MySQL got a non-buffered query function. The problem is that you can have more than one opened non-buffered query in MySQL, so Iit the way it was for a while to give it more time to think of a more realistic solution.So maybe now is the time to move? How do you feel about doing this in Metabase?