[Firebird-devel] ODP: User-defined aggregate functions

2018-10-01 Thread Karol Bieniaszewski
Hi, I know that i am not Firebird core developer and I have less influence. But, why do you still say about WHILE, SUSSPEND, YIELD, FETCH if there is simple alternative to not have it at all? Can someone tell me what is wrong with my proposition?

[Firebird-devel] ODP: User-defined aggregate functions

2018-09-30 Thread Karol Bieniaszewski
>>I think four adjustments makes the initial syntax better: >>- Allow usage of more than one input parameter. Maybe even zero would be >>allowed. ok >> Instead of have special semantics for empty data source, declare the >> constant to be returned for it, say: >> create aggregate

Re: [Firebird-devel] ODP: User-defined aggregate functions

2018-09-29 Thread Mark Rotteveel
On 29-9-2018 16:46, Karol Bieniaszewski wrote: Hi, Maybe i show my concept not so clearly. Look how simple it is with my proposition and also how simple to understand by users. Your syntax looks too much like a normal function, which I think is confusing. How will your proposal work when

[Firebird-devel] ODP: User-defined aggregate functions

2018-09-29 Thread Karol Bieniaszewski
Hi, Maybe i show my concept not so clearly. Look how simple it is with my proposition and also how simple to understand by users. Adriano, below you can see your samples addapted to my concept. Function is called also for empty resultset once then agg_i=0. Agg_i will control the whole

Re: [Firebird-devel] ODP: User-defined aggregate functions

2018-09-28 Thread Adriano dos Santos Fernandes
Karol, If user code something wrongly or create inifinite loops, wrongly results he/she will have, no matter how things are defined. I like your opinion to not limit to only one input parameters. This limitation seems to not have sense. Adriano On 28/09/2018 16:33, Karol Bieniaszewski wrote:

[Firebird-devel] ODP: User-defined aggregate functions

2018-09-28 Thread Karol Bieniaszewski
Hi, First – good concept  But, how this will work? In every WHILE loop, engine will lock loop until next row is „fetched” and susspend is called? I do not know if you understand me? What if function will do not call susspend at all or do not run while loop properly? Maybe this can be done