Skip to content

RPC function returning XML #3389

Answered by guizmo05
guizmo05 asked this question in Q&A
Discussion options

You must be logged in to vote

I've found a solution
just add a domain in postgresql
create domain "*/*" as bytea;

and change the return type of the function with "/"
don't forget to keep:
perform set_config('response.headers', json_build_array(json_build_object('content-Type', 'text/xml'))

and voilà!
-> browser get the good output in xml!
Paul

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by guizmo05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant