Table of Contents Previous Next



7.12 PL/Tcl
PL/Tcl is distributed with EDB Postgres Advanced Server. You must install PL/Tcl in each database (or in a template database) before creating a PL/Tcl function. Use the CREATE LANGUAGE command at the EDB-PSQL command line to install PL/Tcl. Use the psql client to connect to the database in which you wish to install PL/Tcl, and enter the command:
After creating the pltcl language, you can use the features of the PL/Tcl language from within Advanced Server. The following PL/Tcl example creates a function named tcl_max that returns the larger of two integer values:


Table of Contents Previous Next