[MDEV-18825] Document porting of user defined aggregate functions (UDAF) to sql_mode=ORACLE Created: 2019-03-05  Updated: 2019-04-10  Resolved: 2019-04-10

Status: Closed
Project: MariaDB Server
Component/s: Documentation
Affects Version/s: N/A
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: Ian Gilfillan Assignee: Kenneth Dyer (Inactive)
Resolution: Fixed Votes: 0
Labels: None


 Description   

Request via email

I've ported used defined aggregate functions (UDAF) to sql_mode=ORACLE.
Earlier UDAF did note work with sql_mode=ORACLE.

Can you please document this?

Syntactically, an UDAF for sql_mode=ORACLE is
a normal PL/SQL function, with:

1. a FETCH GROUP NEXT ROW statement

2. an EXCEPTION WHEN NO_DATA_FOUND
Note, SQL/PSM-style CONTINUE HANDLER can be used instead of #2 as well,
however we probably don't want to advertise this in the manual.
Please use Oracle's EXCEPTION in examples.

Please find examples in tests in this commit:

https://github.com/mariadb/server/commit/3b47587f419f70687d840c522f4a80e7762b9183

Note, Oracle has UDAFs, but they are implemented using a
different syntax. We'll probably implement Oracle native
syntax for UDAFs later.



 Comments   
Comment by Jacob Moorman (Inactive) [ 2019-04-10 ]

This has been mitigated through updates to:
https://mariadb.com/kb/en/library/sql_modeoracle-from-mariadb-103
https://mariadb.com/kb/en/library/stored-aggregate-functions

Generated at Thu Feb 08 08:47:01 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.