Search Postgresql Archives

Looping through cursor row batches

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Greetings,

I gather the following isn't possible (which would have been elegant and ideal):

FOR rec IN
  FETCH 100000 FROM cursor
LOOP
  ...


Anyone know the most efficient way of FETCHing a batch of rows, and looping through them in a function? FETCHing a record at a time will work, but I was wondering whether this could be done.

Cheers
Henry



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux