Example documentationFUNCTIONS Locate this document in the navigation structure

 

Use of the system table DOMAIN.FUNCTIONS

Prerequisites

You can use the demo data for the SQL tutorial. Start the Database Studio as database administrator MONA with the password RED and log on to demo database DEMODB: Logging On to a Database.

Create database functions. Proceed as described in SQL Tutorial, Database Functions.

Activities

You can use Database Studio to enter and execute SQL statements. More information: Working with SQL Statements: Overview

Note the General Instructions for formulating SQL statements.

You can use the system table FUNCTIONS to determine the following database information, among other things:

  • All database functions of the HOTELschema that were created in the last 10 days

    SELECT schemaname, functionname

    FROM DOMAIN.FUNCTIONS

    WHERE schemaname = 'HOTEL' AND createdate >= SUBDATE(DATE,10)

  • Parameters of the database function AVGPRICE

    SELECT schemaname, functionname, parameter

    FROM DOMAIN.FUNCTIONS

    WHERE functionname = 'AVGPRICE'

More Information

Parameters for a database function: See DBPROCPARAMS