[Gambas-user] Result object, again
tobias
tobiasboe1 at ...20...
Thu Nov 25 20:06:47 CET 2010
Benoît Minisini schrieb:
>> good evening all,
>> i have another question about my eternal punishment: the result object :-)
>>
>> caveat answered to a former question about results in general:
>> >If you got into the habit of reading all the
>> >records you've selected into memory (or even if the Result object
>> >worked
>> >that way behind the scenes...), you'd soon find everything breaking >with
>> >Out Of Memory errors as soon as you start doing anything serious.
>>
>> my question now is, how the result works behind the scenes, is there a
>> counter (result.index?) that tells a layer (the driver?) which record is
>> to be given back?
>>
>> regards,
>> tobi
>>
>
> A result object stores the entire query of the result in memory, because of
> the stupidity of most SQL backends.
>
> The gb.db.form implements a system that only keep a small part of the query
> result, by using the ">" operator on the table key, "Order By", and the
> Limit() method. That way, you can use a DataBrowser to browse a table that is
> located on a far server easily.
>
> Regards,
>
thank you!
but at the moment, i don't think about the db related controls...
ok, so the result stores just the query in memory and on demand, it
loads the next (according to Result.Index) result entry, right? is there
another internal pointer?
i hopefully finish my research paper (dict.cc told me that this is a
good word for it :-) ) the next days, i think, it would be found then
somewhere at gambas-club.de or gambas-projekt.de ...
regards, tobi
More information about the User
mailing list