Re: functions in WHERE clause

Поиск
Список
Период
Сортировка
От Michael Fuhr
Тема Re: functions in WHERE clause
Дата
Msg-id 20060305172635.GA77911@winnie.fuhr.org
обсуждение исходный текст
Ответ на functions in WHERE clause  (sramsay@uga.edu)
Ответы Re: functions in WHERE clause  (sramsay@uga.edu)
Список pgsql-sql
On Sun, Mar 05, 2006 at 10:16:52AM -0500, sramsay@uga.edu wrote:
> I've got one of these:
> 
> SELECT * from some_table WHERE
> test_for_equality_is_syntactically_ugly;
> 
> What I'd like to do is encapsulate the WHERE clause in a function,
> but I'm having no end of trouble.

Would a view work?  If not then please provide a more concrete
example that shows what you're trying to do.

CREATE VIEW foo AS
SELECT * FROM some_table
WHERE test_for_equality_is_syntactically_ugly;

-- 
Michael Fuhr


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

Предыдущее
От: sramsay@uga.edu
Дата:
Сообщение: functions in WHERE clause
Следующее
От: sramsay@uga.edu
Дата:
Сообщение: Re: functions in WHERE clause