Re: Help with Select Statement

Поиск
Список
Период
Сортировка
От Nabil Sayegh
Тема Re: Help with Select Statement
Дата
Msg-id 4074F3CE.9040409@e-trolley.de
обсуждение исходный текст
Ответ на Re: Help with Select Statement  (Kevin Lohka <klohka@aboutfacedata.ab.ca>)
Список pgsql-novice
Kevin Lohka wrote:
> Thanks for you response Nabil, I'm not sure if it solves my problem as
> there may be multiple records in the "bar" table, but I'll work through it.

There are several ways to return only 1 result out of many:
GROUP BY ( for aggregate functions like max, min, avg )
DISTINCT ( quick & dirty ;)
LIMIT    ( probably together with ORDER BY cut the result )

And remember: whenever you run into a hopeless situation: you can still use
subqueries in postgresql :)

--
  e-Trolley Sayegh & John, Nabil Sayegh
  Tel.: 0700 etrolley /// 0700 38765539
  Fax.: +49 69 8299381-8
  PGP : http://www.e-trolley.de

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: pg_dump filling up root directory
Следующее
От: "Sheeraz fazal"
Дата:
Сообщение: How to call a function of PL/pgSQL