• Tom Lane's avatar
    Fix aboriginal mistake in plpython's set-returning-function support. · add0ea88
    Tom Lane authored
    We must stay in the function's SPI context until done calling the iterator
    that returns the set result.  Otherwise, any attempt to invoke SPI features
    in the python code called by the iterator will malfunction.  Diagnosis and
    patch by Jan Urbanski, per bug report from Jean-Baptiste Quenot.
    
    Back-patch to 8.2; there was no support for SRFs in previous versions of
    plpython.
    add0ea88
plpython_setof.sql 1.59 KB