reference:metaindexes
Differences
This shows you the differences between two versions of the page.
| reference:metaindexes [2015/08/12 01:29] – created mnewnham | reference:metaindexes [2015/08/12 02:05] (current) – removed mnewnham | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | ====== metaIndexes ====== | ||
| - | ~~NOTOC~~ | ||
| - | <WRAP right box> | ||
| - | == See Also == | ||
| - | [[reference: | ||
| - | |||
| - | == Syntax == | ||
| - | mixed metaIndexes( | ||
| - | string $tableName, | ||
| - | optional bool $primary=true, | ||
| - | optional string $owner=false, | ||
| - | ) | ||
| - | </ | ||
| - | ===== Description ===== | ||
| - | The function '' | ||
| - | |||
| - | <code php> | ||
| - | [index_name] => Array | ||
| - | ( | ||
| - | [unique] => 0 | ||
| - | [columns] => Array | ||
| - | ( | ||
| - | [0] => Column 1 | ||
| - | [1] => Column 2 | ||
| - | [2] => etc........ | ||
| - | ) | ||
| - | |||
| - | ) | ||
| - | </ | ||
| - | |||
| - | The casing of metaIndexes is returned in the native mode for the database, you should not assume the casing for the returned data. | ||
| - | |||
| - | ===== Optional Parameters ===== | ||
| - | ==== $primary ==== | ||
| - | If set, only returns the index associated with the primary key | ||
| - | |||
| - | ==== $owner ==== | ||
| - | If specified, only returns indexes associated with a table owned by that name. Support for this function is limited, see the compatibility matrix. | ||
| - | ===== Usage ===== | ||
| - | <code php> | ||
| - | /* | ||
| - | * Database connection to DB2 database sample assumed | ||
| - | */ | ||
| - | $mi = $db-> | ||
| - | print_r($mi); | ||
| - | /* | ||
| - | * Returns | ||
| - | Array | ||
| - | ( | ||
| - | [PK_ACT] => Array | ||
| - | ( | ||
| - | [unique] => 0 | ||
| - | [columns] => Array | ||
| - | ( | ||
| - | [0] => ACTNO | ||
| - | ) | ||
| - | |||
| - | ) | ||
| - | |||
| - | [XACT2] => Array | ||
| - | ( | ||
| - | [unique] => 0 | ||
| - | [columns] => Array | ||
| - | ( | ||
| - | [0] => ACTNO | ||
| - | [1] => ACTKWD | ||
| - | ) | ||
| - | |||
| - | ) | ||
| - | |||
| - | ) | ||
| - | */ | ||
| - | </ | ||
reference/metaindexes.1439335747.txt.gz · Last modified: (external edit)
