Re: plpython does not honour max-rows

From: Daniel Gustafsson <daniel(at)yesql(dot)se>
To: Kieran McCusker <kieran(dot)mccusker(at)gmail(dot)com>
Cc: pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: plpython does not honour max-rows
Date: 2023-05-02 11:01:00
Message-ID: 711512C7-2BC2-4901-A368-6A5A23023F72@yesql.se
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

> On 2 May 2023, at 12:30, Kieran McCusker <kieran(dot)mccusker(at)gmail(dot)com> wrote:

> I came across this when developing a sampling function using plpy.execute that needs to be able to sample zero rows. What actually happens is that zero is ignored for max-rows and all rows are returned.

A max_rows of less than or equal to zero is IIRC interpreted as "fetch all
rows". I think this works as intended, is it documented anywhere to work in
another way?

--
Daniel Gustafsson

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Kieran McCusker 2023-05-02 11:37:00 Re: plpython does not honour max-rows
Previous Message Daniel Gustafsson 2023-05-02 10:34:59 Re: pg_basebackup: errors on macOS on directories with ".DS_Store" files