Re: Last call for comments: fmgr rewrite [LONG]
От | Peter Eisentraut |
---|---|
Тема | Re: Last call for comments: fmgr rewrite [LONG] |
Дата | |
Msg-id | Pine.LNX.4.21.0005222337400.392-100000@localhost.localdomain обсуждение исходный текст |
Ответ на | Last call for comments: fmgr rewrite [LONG] (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-hackers |
I just got my hands on the real SQL99 stuff, dated September 1999, and it contains a function creation syntax that is strikingly similar to ours, which would make it a shame not to at least try to play along. Below is a heavily reduced BNF which should give you some idea -- note in particular the NULL call conventions. Download your copy at <ftp://jerry.ece.umassd.edu/isowg3/x3h2/Standards/>. <schema function> ::= CREATE FUNCTION <schema qualified name> <SQL parameter declarationlist> RETURNS <data type> [ <routine characteristics>... ] [ <dispatchclause> ] <routine body> <dispatch clause> ::= STATIC DISPATCH /* no idea */ <SQL parameter declaration list> ::= <left paren> [ <SQL parameter declaration> [ { <comma><SQL parameter declaration> }... ] ] <right paren> <SQL parameter declaration> ::= [ <parameter mode> ] [ <SQL parameter name> ] <parametertype> [ RESULT ] <parameter mode> ::= IN | OUT | INOUT /* default is IN */ <routine body> ::= <SQL routine body> | <external body reference> <SQL routine body>::= <SQL procedure statement> /* which means a particular subset of SQL statements */ <external body reference>::= EXTERNAL [ NAME <external routine name> ] [ <parameter style clause> ] [ <external security clause> ] <routine characteristic> ::= LANGUAGE { ADA | C | COBOL | FORTRAN | MUMPS | PASCAL | PLI | SQL } | PARAMETER STYLE { SQL | GENERAL } | SPECIFIC <specific name> /* apparently to disambiguate overloadedfunctions */ | { DETERMINISTIC | NOT DETERMINISTIC } | { NO SQL | CONTAINS SQL | READSSQL DATA | MODIFIES SQL DATA } | { RETURNS NULL ON NULL INPUT | CALLED ON NULL INPUT } ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | <transform group specification> | <dynamic resultsets characteristic> -- Peter Eisentraut Sernanders väg 10:115 peter_e@gmx.net 75262 Uppsala http://yi.org/peter-e/ Sweden
В списке pgsql-hackers по дате отправления: