xml in ruleutils - Mailing list pgsql-hackers

From andrzej barszcz
Subject xml in ruleutils
Date
Msg-id 1247323023.16438.35.camel@ab-desktop
Whole thread Raw
Responses Re: xml in ruleutils
List pgsql-hackers
Hi,

Well, best to write this way:

Goal : query splitted to base elements
Result : xml response from server
Client : select pg_reparse_query(<query>);
Target: 8.4 version

How : modification of ruleutiles.c
Not done : UNION etc.
Not done : as builtin function, I don't know how to do it )))
Tested : partly


examples :

query : ( not meaningful by the way )

pzty - View on table X
"wartość zakupu" - from View of table Y
"nazwa dostawcy" - from Table Z

select public.pg_reparse_query($$with xxx as (select * from pzty) select
ctid,upper("nazwa dostawcy") from xxx where typ_dok='PZ' or typ_dok='WZ'
and "nazwa dostawcy" = 'A' and "wartość zakupu" = 100 order by "nazwa
dostawcy" desc $$);

second example:

select public.pg_reparse_query($$select ctid,upper("nazwa dostawcy")
from pzty where typ_dok='PZ' or typ_dok='WZ' and "nazwa dostawcy" = 'A'
and "wartość zakupu" = 100 order by "nazwa dostawcy" desc $$);


Does it make sense ????


If you are interested in this solution send me email please.


best regards
Andrzej Barszcz





Attachment

pgsql-hackers by date:

Previous
From: Shane Ambler
Date:
Subject: Re: Odd historical fact about Bison
Next
From: Josh Berkus
Date:
Subject: Re: Odd historical fact about Bison