(無版本資訊,可能僅在 Git 中)
TableUpdate::limit — 限制更新列數
rows
要更新的記錄或文件的最大數量。
一個 TableUpdate 物件。
範例 #1 mysql_xdevapi\TableUpdate::limit() 範例
<?php
$session = mysql_xdevapi\getSession("mysqlx://user:password@localhost");
$schema = $session->getSchema("addressbook");
$table = $schema->getTable("names");
$res = $table->update()
->set('level', 3)
->where('age > 15 and age < 22')
->limit(4)
->orderby(['age asc','name desc'])
->execute();
?>