]> granicus.if.org Git - postgresql/commit - src/pl/plpgsql/src/pl_comp.c
Implement the DO statement to support execution of PL code without having
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 22 Sep 2009 23:43:43 +0000 (23:43 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 22 Sep 2009 23:43:43 +0000 (23:43 +0000)
commit9048b73184b6852b71faf4481b75ab5850a9cd1b
tree445092b67a93cf16300f72e41f14d8ad3443188f
parentd5a43ffde068d67409b494d812bd7e9f514db29c
Implement the DO statement to support execution of PL code without having
to create a function for it.

Procedural languages now have an additional entry point, namely a function
to execute an inline code block.  This seemed a better design than trying
to hide the transient-ness of the code from the PL.  As of this patch, only
plpgsql has an inline handler, but probably people will soon write handlers
for the other standard PLs.

In passing, remove the long-dead LANCOMPILER option of CREATE LANGUAGE.

Petr Jelinek
34 files changed:
doc/src/sgml/catalogs.sgml
doc/src/sgml/config.sgml
doc/src/sgml/keywords.sgml
doc/src/sgml/ref/allfiles.sgml
doc/src/sgml/ref/create_language.sgml
doc/src/sgml/ref/do.sgml [new file with mode: 0644]
doc/src/sgml/reference.sgml
doc/src/sgml/xplang.sgml
src/backend/catalog/pg_proc.c
src/backend/commands/functioncmds.c
src/backend/commands/proclang.c
src/backend/nodes/copyfuncs.c
src/backend/nodes/equalfuncs.c
src/backend/parser/gram.y
src/backend/tcop/utility.c
src/backend/utils/misc/guc.c
src/backend/utils/misc/postgresql.conf.sample
src/bin/pg_dump/pg_dump.c
src/bin/pg_dump/pg_dump.h
src/bin/scripts/droplang.c
src/include/catalog/catversion.h
src/include/catalog/pg_language.h
src/include/catalog/pg_pltemplate.h
src/include/commands/defrem.h
src/include/nodes/nodes.h
src/include/nodes/parsenodes.h
src/include/parser/kwlist.h
src/include/utils/guc.h
src/interfaces/ecpg/preproc/ecpg.trailer
src/pl/plpgsql/src/pl_comp.c
src/pl/plpgsql/src/pl_handler.c
src/pl/plpgsql/src/plpgsql.h
src/test/regress/expected/plpgsql.out
src/test/regress/sql/plpgsql.sql