PHP 8.5.0 Beta 3 available for testing

TableUpdate::bind

(No version information available, might only be in Git)

TableUpdate::bind โ€” update ใฎใ‚ฏใ‚จใƒชใƒ‘ใƒฉใƒกใƒผใ‚ฟใ‚’ใƒใ‚คใƒณใƒ‰ใ™ใ‚‹

่ชฌๆ˜Ž

public mysql_xdevapi\TableUpdate::bind(array $placeholder_values): mysql_xdevapi\TableUpdate

็‰นๅฎšใฎใƒ—ใƒฌใƒผใ‚นใƒ›ใƒซใƒ€ใƒผใฎๅ€คใ‚’ใƒใ‚คใƒณใƒ‰ใ—ใพใ™ใ€‚

ใƒ‘ใƒฉใƒกใƒผใ‚ฟ

placeholder_values

ใƒ—ใƒฌใƒผใ‚นใƒ›ใƒซใƒ€ใƒผใฎๅๅ‰ใ€ใŠใ‚ˆใณใƒใ‚คใƒณใƒ‰ใ™ใ‚‹ๅ€คใงใ™ใ€‚ JSON ใฎ้…ๅˆ—ใจใ—ใฆๅฎš็พฉใ•ใ‚Œใพใ™ใ€‚

ๆˆปใ‚Šๅ€ค

TableUpdate ใ‚ชใƒ–ใ‚ธใ‚งใ‚ฏใƒˆใ‚’่ฟ”ใ—ใพใ™ใ€‚

ไพ‹

ไพ‹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();

?>
๏ผ‹add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top