ADOdb

Database Abstraction Layer for PHP

User Tools

Site Tools


v5:dictionary:metaprocedures

metaProcedures

See Also

prepareSp

Syntax
function metaProcedures(
 optional string $namePattern=null,
 optional string $catalog=null,
 optional string $schemaPattern=null

)

Description

The function metaProcedures() returns a list of stored procedures in a database. Some databases do not support stored procedures. The format of the data returned is as follows:


Array(
  [name_of_procedure] => Array(
      [type] => PROCEDURE or FUNCTION or METHOD
      [catalog] => Catalog (or owner) name
      [schema] => Schema name
      [remarks] => explanatory comment on the procedure
   )
)

Parameters

$namePattern

An optional wildcard pattern match on the name of the procedure.

$catalog

An optional wildcard pattern match on the catalog (or owner) of the procedure.

$schemaPattern

An optional wildcard pattern match on the schema of the procedure.

Usage

$mp = $db->metaProcedures('proc_sample%','db2inst1'));
print_r($mp)
/*
 * Prints
Array
Array
(
    [PROC_SAMPLE1] => Array
        (
            [type] => PROCEDURE
            [catalog] => DB2INST1
            [schema] => DB2INST1
            [remarks] =>
        )
 
)
 
*/
v5/dictionary/metaprocedures.txt · Last modified: 2016/01/19 19:33 by 66.249.64.108