TableUpdate::bind
(사용 가능한 버전 정보가 없으며 Git에만 있을 수 있음)
TableUpdate::bind — Bind update query parameters
설명
public mysql_xdevapi\TableUpdate::bind(array $placeholder_values
): mysql_xdevapi\TableUpdate
특정 자리 표시자에 값을 바인딩합니다.
매개변수
placeholder_values
- JSON 배열로 정의된 자리 표시자의 이름과 바인딩할 값입니다.
반환 값
TableUpdate 개체입니다.
Examples
예제 #1 mysql_xdevapi\TableUpdate::bind() 예제
<?php
$session = mysql_xdevapi\getSession("mysqlx://user:password@localhost");
$schema = $session->getSchema("addressbook");
$table = $schema->getTable("names");
$table->update()
->set('status', 'admin')
->where('name = :name and age > :age')
->bind(['name' => 'Bernie', 'age' => 2000])
->execute();
?>