Re: modifying the table function
От | Islam Hegazy |
---|---|
Тема | Re: modifying the table function |
Дата | |
Msg-id | 035e01c78209$22c76d40$0d0e9f88@pc.cpsc.ucalgary.ca обсуждение исходный текст |
Ответ на | modifying the table function ("Islam Hegazy" <islheg@gmail.com>) |
Ответы |
Re: modifying the table function
|
Список | pgsql-hackers |
Thanks for the documentation link. It helped me to understand how data are passed back to the client. I figured out that data is sent back to the client using the 'printtup' function. It is called by ExecSelect, called by ExecutorRun, etc. What I understand now is that the data is sent to the client and stored there until the client receives a message from the server to display it. The server sends the display message from within 'ReadyForQuery' but I can't figure it out. What I expect is that when I call 'exec_simple_query' several times, the server sends one row only for each call. But since they are separate calls, the client overwrites the previous results or saves the new row in a new place in memory such that it displays the last row only when the server invokes 'ReadyForQuery'. I wonder if I am on the right track or not and how to know such kind of message sent from the server? Regards Islam Hegazy ----- Original Message ----- From: "Tom Lane" <tgl@sss.pgh.pa.us> To: "Islam Hegazy" <islheg@gmail.com> Cc: <pgsql-hackers@postgresql.org> Sent: Tuesday, April 17, 2007 1:44 AM Subject: Re: [HACKERS] modifying the table function > "Islam Hegazy" <islheg@gmail.com> writes: >> My question is how to inform the client that there is a tuple to display >> = >> and return back to the backend to continue the query execution? > > I'd suggest you start by reading > http://developer.postgresql.org/pgdocs/postgres/protocol.html > and then develop a clear specification at that level of what you > think should happen. Perhaps after that exercise it will be clearer > how to change the code. "Think first, program later." > > regards, tom lane
В списке pgsql-hackers по дате отправления: