Most PostgreSQL functions are wrapper functions for libpq. Reading documents
about libpq will help.

Answer to your question is, it does not read all data into memory. I think most
DB doesn't do that also.

Data will be buffered in PostgreSQL backend, size is depends on your
configuration.
I'm not sure if it buffers on client side.

Regards,
--
Yasuo Ohgaki


"Morgan Curley" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Just out of curiosity, can anyone explain the mechanics behind accessing a
> database query result set.
> ie
> $result_id = pg_execute( 'select * from my_table' );
>
> when I call loop through pg_fetch_row( $result_id, $rom_num ) or
> pg_fetch_object( $result_id, $rom_num )
> has php read the entire result set into memory( say the result set has
> 10,000 records ), cached a fixed number of records in memory or does it
> simply have a record_set_pointer of some sort that tells the DB where to
> fetch the next asked for record from.
>
> This is probably a DB engine setting but I am curious what the process is.
>
> Thanks,
> Morgan
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to