Re: [HACKERS] Shared sequence-like objects in PostgreSQL

2011-09-21 Thread Greg Stark
On Wed, Sep 21, 2011 at 8:19 AM, Vlad Arkhipov wrote: > I'm writing a C-language function that is similar to nextval() but should > return the next member of the recurrent sequence: > T(n+1) = f(T(n), T(n-1), ..., T(n-k)), where f is some function and k is a > constant. > The state of this object

[HACKERS] Shared sequence-like objects in PostgreSQL

2011-09-21 Thread Vlad Arkhipov
Hello all, I'm writing a C-language function that is similar to nextval() but should return the next member of the recurrent sequence: T(n+1) = f(T(n), T(n-1), ..., T(n-k)), where f is some function and k is a constant. The state of this object should be persistent between database restarts an