Crossed Reference Query

Поиск
Список
Период
Сортировка
От Eduardo Mylonas - Externo
Тема Crossed Reference Query
Дата
Msg-id 002301c34ca3$718c34a0$d4076564@automat
обсуждение исходный текст
Ответы Re: Crossed Reference Query  (Joe Conway <mail@joeconway.com>)
Re: Crossed Reference Query  (Dennis Gearon <gearond@cvc.net>)
Список pgsql-general

MS Access has a functionality which is a type of query called "Crossed
Reference Query" (At least, that's the lame translation i got to come up
with).

The syntax is something like this:
TRANSFORM Max(Consulta1.nome) AS [O valor]
SELECT Consulta1.usuario_id, Max(Consulta1.nome) AS [Total de nome]
FROM Consulta1
GROUP BY Consulta1.usuario_id
PIVOT Consulta1.textoitem;

The query Consulta1 is:
SELECT sig_permissoes.usuario_id, sig_menudecontrole.textoitem,
sig_niveis.nome
FROM sig_niveis INNER JOIN (sig_menudecontrole INNER JOIN sig_permissoes ON
sig_menudecontrole.menu_id = sig_permissoes.menu_id) ON sig_niveis.nivel_id
= sig_permissoes.nivel_id
ORDER BY sig_permissoes.usuario_id, sig_menudecontrole.painel_id,
sig_menudecontrole.numeroitem;

Well, i want to know whether is possible to do something like this over
PostgreSQL. If it's needed perl scripts or some other type of scripting, for
me that's ok. the thing is that i need to have that.

Is it possible?

Thanks to all.

Eduardo Mylonas da Silva
Automat Eng. de Automação
Desenvolovimento
mailto: emylonas@automat.com.br
www.automat.com.br


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

Предыдущее
От: Network Administrator
Дата:
Сообщение: Re: Are you frustrated with PostgreSQL
Следующее
От: "Dick Wieland"
Дата:
Сообщение: what's the scope of psql parameter values?