Re: PL/Python result object str handler

Поиск
Список
Период
Сортировка
От Magnus Hagander
Тема Re: PL/Python result object str handler
Дата
Msg-id CABUevEwoqa-tOK+HjyhO7sk4CB9RJjouvdC=yt6fnV7-X5TQuA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: PL/Python result object str handler  (Peter Eisentraut <peter_e@gmx.net>)
Список pgsql-hackers
On Tue, Jan 8, 2013 at 10:23 PM, Peter Eisentraut <peter_e@gmx.net> wrote:
> On 1/8/13 4:32 AM, Magnus Hagander wrote:
>> How does it work if there are many rows in there? Say the result
>> contains 10,000 rows - will the string contain all of them? If so,
>> might it be worthwhile to cap the number of rows shown and then follow
>> with a "..." or something?
>
> I don't think so.  Any number you pick will be too low for someone.
> Since this would only be executed when explicitly asked for, it's up to
> the user to manage this.  It's analogous to print(long_list) -- you
> wouldn't truncate that.

Fair enough. I was thinking of a specific example when I wrote that,
bu I can't recall what it was, and clearly using print or the python
console would be the most similar scenarios. And they both do it the
way you suggest. So that's probably the right thing to do.

--Magnus HaganderMe: http://www.hagander.net/Work: http://www.redpill-linpro.com/



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: PL/Python result object str handler
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: PL/Python result object str handler