ADOdb

Database Abstraction Layer for PHP

User Tools

Site Tools


v5:dictionary:metaprocedures

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
Next revisionBoth sides next revision
dictionary:metaprocedures [2015/08/12 02:07] – created mnewnhamdictionary:metaprocedures [2015/12/29 03:37] mnewnham
Line 1: Line 1:
 ====== metaProcedures ====== ====== metaProcedures ======
-<WRAP info> +~~NOTOC~~
-Support for this function is limited to [[driver:postgres|Postgres]] and [[driver:mysql|MySQL]] databases. +
-</WRAP>+
 <WRAP right box> <WRAP right box>
 +== See Also ==
 +[[reference:prepareSp()]]
 == Syntax == == Syntax ==
-    function metaProcedures( +  function metaProcedures( 
-             optional string $namePattern=false+   optional string $namePattern=null
-             optional string $catalog=null, +   optional string $catalog=null, 
-             optional string $schemaPattern=null +   optional string $schemaPattern=null 
-             ) + )
-</WRAP> +
-<WRAP todo> +
-Page under construction+
 </WRAP> </WRAP>
 +===== 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 =====
 +<code php>
 +
 +$mp = $db->metaProcedures('proc_sample%','db2inst1'));
 +print_r($mp)
 +/*
 + * Prints
 +Array
 +Array
 +(
 +    [PROC_SAMPLE1] => Array
 +        (
 +            [type] => PROCEDURE
 +            [catalog] => DB2INST1
 +            [schema] => DB2INST1
 +            [remarks] =>
 +        )
 +
 +)
 +
 +*/
 +</code>
v5/dictionary/metaprocedures.txt · Last modified: 2016/01/19 19:33 by 66.249.64.108