update : 2015.11.03
php.shukuma.com검색:
|
PDOStatement::bindColumn(PHP 5 >= 5.1.0, PECL pdo >= 0.1.0) PDOStatement::bindColumn — Bind a column to a PHP variable 설명
public bool PDOStatement::bindColumn
( mixed
$column
, mixed &$param
[, int $type
[, int $maxlen
[, mixed $driverdata
]]] )PDOStatement::bindColumn() arranges to have a particular variable bound to a given column in the result-set from a query. Each call to PDOStatement::fetch() or PDOStatement::fetchAll() will update all the variables that are bound to columns.
인수
반환값
성공 시 예제
Example #1 Binding result set output to PHP variables Binding columns in the result set to PHP variables is an effective way to make the data contained in each row immediately available to your application. The following example demonstrates how PDO allows you to bind and retrieve columns with a variety of options and with intelligent defaults.
<?php 위 예제의 출력: apple red 150 banana yellow 175 kiwi green 75 orange orange 150 mango red 200 strawberry red 25 참고
|