Re: "Custom" records?

Поиск
Список
Период
Сортировка
От Peter Darley
Тема Re: "Custom" records?
Дата
Msg-id NNEAICKPNOGDBHNCEDCPKEJJCOAA.pdarley@kinesis-cem.com
обсуждение исходный текст
Ответ на "Custom" records?  (Joel Palmius <joel.palmius@mh.se>)
Ответы Re: "Custom" records?  (Masaru Sugawara <rk73@sea.plala.or.jp>)
Список pgsql-general
Joel,
    I don't have an answer for this, but I do have a question.
    I couldn't find any way to get a median native in PostgreSQL, did you write
a median function or some such?  If so, would you be willing to share it?
Thanks,
Peter Darley

-----Original Message-----
From: pgsql-general-owner@postgresql.org
[mailto:pgsql-general-owner@postgresql.org]On Behalf Of Joel Palmius
Sent: Thursday, September 19, 2002 2:53 AM
To: pgsql-general
Subject: [GENERAL] "Custom" records?


Before asking this, I suspect that the answer is no, but I'll ask anyway.

Is there a way to return a completely custom column/row record from a
plpgsql function?

I'd want a function "Descriptives(int)" with results to looking like the
below when SELECT:ed :

  measurement | value
  ------------+------
  Mean        |  15.8
  Median      |  16.0
  Std.dev     |   0.8
  Max         |  38.0
  Min         |   0.0

If not possible in plpgsql, is there a workaround while still not having
an external program fetching a lot of data from the DB to do the
calculation?

  // Joel



---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org


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

Предыдущее
От: "Peter Darley"
Дата:
Сообщение: Re: Buffer Analysis
Следующее
От: Oliver Elphick
Дата:
Сообщение: Re: rotatelog / logrotate with PostgreSQL