Dynamic limit for the number of records?

Поиск
Список
Период
Сортировка
От Murali Mohan Kasetty
Тема Dynamic limit for the number of records?
Дата
Msg-id 3D9EC259.38AC3D40@india.hp.com
обсуждение исходный текст
Ответы Re: Dynamic limit for the number of records?
Список pgsql-general
Hi all,

Is there a way to dynamically limit the number of records in a view
based on
the number of records in another table. Her e is an example:

I have two views VIEW1 and VIEW2.
The total number of records in VIEW1 and VIEW2 should be 20. So, if
VIEW1
has 10 records VIEW2 should have only 20 records, if VIEW1 has 5 records

then VIEW2 should have only 25 records.

I have tried LIMIT to limit the number of records. BUt, LIMIT requires
that
the number of recors be static. A
If somebody has faced this situation and knows of a solution, please let
me
know.

Best Regards
- Geetha
----------------------------------------------------
Hewlett Packard (India)
+91 80 2051382 (Phone)
847 1382 (HP Telnet)
----------------------------------------------------

Вложения

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

Предыдущее
От: Jeff Davis
Дата:
Сообщение: Re: Boolean output format
Следующее
От: Martijn van Oosterhout
Дата:
Сообщение: Server locale?