Re: [GENERAL] log temp files are created twice in PL/pgSQL function

2016-03-19 Thread Adrian Klaver
On 03/16/2016 07:58 AM, Dang Minh Huong wrote: Hi, Why does log temp files are created twice when query is executed in PL/pgSQL function? Would you please explain it to me? As below test result. Log temp files are created twice when SELECT statement is put into a PL/pgSQL function. It led

Re: [GENERAL] log temp files are created twice in PL/pgSQL function

2016-03-19 Thread Pavel Stehule
Hi 2016-03-16 15:58 GMT+01:00 Dang Minh Huong : > Hi, > > Why does log temp files are created twice when query is executed in > PL/pgSQL function? > Would you please explain it to me? > PL/pgSQL materialize result internally. Usually PostgreSQL operations are executed row by row. But some SRF f

[GENERAL] log temp files are created twice in PL/pgSQL function

2016-03-19 Thread Dang Minh Huong
Hi, Why does log temp files are created twice when query is executed in PL/pgSQL function? Would you please explain it to me? As below test result. Log temp files are created twice when SELECT statement is put into a PL/pgSQL function. It led a little of performance degradation. Is there any

Re: [GENERAL] log temp files are created twice in PL/pgSQL function

2016-03-19 Thread Dang Minh Huong
Hi, Thanks for your prompt response. Appreciate your help. Thanks and best regards, bocap > Hi > > 2016-03-16 15:58 GMT+01:00 Dang Minh Huong : >> Hi, >> >> Why does log temp files are created twice when query is executed in PL/pgSQL >> function? >> Would you please explain it to me? > > PL/