Information Schema ROUTINES Table

The Information Schema ROUTINES table stores information about stored procedures and stored functions.

It contains the following columns:

ColumnDescription
SPECIFIC_NAME
ROUTINE_CATALOGAlways def.
ROUTINE_SCHEMADatabase name associated with the routine.
ROUTINE_NAMEName of the routine.
ROUTINE_TYPEWhether the routine is a PROCEDURE or a FUNCTION.
DATA_TYPEThe return value's data type (for stored functions).
CHARACTER_MAXIMUM_LENGTHMaximum length.
CHARACTER_OCTET_LENGTHSame as the CHARACTER_MAXIMUM_LENGTH except for multi-byte character sets.
NUMERIC_PRECISIONFor numeric types, the precision (number of significant digits) for the column. NULL if not a numeric field.
NUMERIC_SCALEFor numeric types, the scale (significant digits to the right of the decimal point). NULL if not a numeric field.
DATETIME_PRECISIONFractional-seconds precision, or NULL if not a time data type.
CHARACTER_SET_NAMECharacter set if a non-binary string data type, otherwise NULL.
COLLATION_NAMECollation if a non-binary string data type, otherwise NULL.
DATA_TYPEThe column's data type.
ROUTINE_BODYAlways SQL.
ROUTINE_DEFINITIONDefinition of the routine.
EXTERNAL_NAMEAlways NULL.
EXTERNAL_LANGUAGEAlways SQL.
PARAMETER_STYLEAlways SQL.
IS_DETERMINISTICWhether the routine is deterministic (can produce only one result for a given list of parameters) or not.
SQL_DATA_ACCESSOne of READS SQL DATA, MODIFIES SQL DATA, CONTAINS SQL, or NO SQL.
SQL_PATHAlways NULL.
SECURITY_TYPEINVOKER or DEFINER. Indicates which user's privileges apply to this routine.
CREATEDDate and time the routine was created.
LAST_ALTEREDDate and time the routine was last changed.
SQL_MODEThe SQL_MODE at the time the routine was created.
ROUTINE_COMMENTComment associated with the routine.
DEFINERIf the SECURITY_TYPE is DEFINER, this value indicates which user defined this routine.
CHARACTER_SET_CLIENTThe character set used by the client that created the routine.
COLLATION_CONNECTIONThe collation (and character set) used by the connection that created the routine.
DATABASE_COLLATIONThe default collation (and character set) for the database, at the time the routine was created.

It provides information similar to, but more complete, than the SHOW PROCEDURE STATUS and SHOW FUNCTION STATUS statements.

For information about the parameters accepted by the routine, you can query the information_schema.PARAMETERS table.

See also

Comments

Comments loading...
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.