|
PDOStatement::getColumnMetaReturns metadata for a column in a result set Beschreibung
public array PDOStatement::getColumnMeta
( int
$column
)Retrieves the metadata for a 0-indexed column in a result set as an associative array. Warnung
Not all PDO drivers support PDOStatement::getColumnMeta. The following drivers support this method: Parameter-Liste
RückgabewerteReturns an associative array containing the following values representing the metadata for a single column:
Returns Beispiele
Beispiel #1 Retrieving column metadata The following example shows the results of retrieving the metadata for a single column generated by a function (COUNT) in a PDO_SQLITE driver.
<?phpDas oben gezeigte Beispiel erzeugt folgende Ausgabe:
array(6) {
["native_type"]=>
string(7) "integer"
["flags"]=>
array(0) {
}
["name"]=>
string(8) "COUNT(*)"
["len"]=>
int(-1)
["precision"]=>
int(0)
["pdo_type"]=>
int(2)
}
Siehe auch
|