stored queries

Поиск
Список
Период
Сортировка
От Joop
Тема stored queries
Дата
Msg-id pan.2003.12.23.09.23.24.185553@localhost.localdomain.invalid
обсуждение исходный текст
Список pgsql-sql
Hello everyone,

I'm just about to start on the reporting part of a PostgreSQL / PHP
application. I think it would be a good idea to create a table in my db in
which I can store queries, something like this:

create table stored_queries ( id bigint primary key, name varchar, description varchar, parameters varchar[][], query
text
);

The frontend to it would present the user with a choice of the NAMEs of
the records, check if PARAMETERs are required (the dimensions would be
name and datatype), if so ask for the parameters and eventually run QUERY
with these parameters.

This approach seems very logical to me, so I think someone must have
invented this weel already :-). I googled for "stored queries" but didn't
find much. I would really like tips, feedback on this approach. Is it a
bad idea, and if so, why? What pitfalls will I run into?

Thanks!


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

Предыдущее
От: A E
Дата:
Сообщение: Use of Setof Record Dynamically
Следующее
От: teknokrat
Дата:
Сообщение: Re: how do i get differences between rows