Re: [PERFORM] View containing a recursive function

2016-02-05 Thread Mathieu De Zutter
On Mon, 1 Feb 2016 at 10:45 Tom Lane wrote: > Mathieu De Zutter writes: > Assuming you have a reasonably late-model PG, you could rewrite the > view with a lateral function call: > > CREATE OR REPLACE VIEW covering_works_r AS > SELECT > w.id

Re: [PERFORM] View containing a recursive function

2016-02-01 Thread Tom Lane
Mathieu De Zutter writes: > I have a recursive part in my database logic that I want to isolate and > reuse as a view. I had found a blog that explained how move a function > parameter into a view. The SQL is in attachment. > When I write a query based on that view with a

[PERFORM] View containing a recursive function

2016-01-31 Thread Mathieu De Zutter
Hi all, I have a recursive part in my database logic that I want to isolate and reuse as a view. I had found a blog that explained how move a function parameter into a view. The SQL is in attachment. When I write a query based on that view with a fixed value (or values) for the (input) parameter,