Skip to content

Commit 5e8532e

Browse files
committed
Fix user guide
1 parent 3a444ae commit 5e8532e

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

system/Database/BaseBuilder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1969,7 +1969,7 @@ protected function _upsertBatch(string $table, array $keys, array $values): stri
19691969
}
19701970

19711971
/**
1972-
* Set table alias for dataset sudo table.
1972+
* Set table alias for dataset pseudo table.
19731973
*/
19741974
public function setAlias(string $alias): BaseBuilder
19751975
{

user_guide_src/source/database/query_builder.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1118,6 +1118,8 @@ Generates a batch **DELETE** statement based on a set of data.
11181118

11191119
This method may be especially useful when deleting data in a table with a composite primary key.
11201120

1121+
.. note:: SQLite does not support the use of ``where()``.
1122+
11211123
$builder->emptyTable()
11221124
----------------------
11231125

user_guide_src/source/database/query_builder/118.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@
2121
],
2222
];
2323

24-
$builder->setAlias('del')->where('order_line.qty >', 1)->deleteBatch($data, 'order, line');
24+
$builder->setAlias('del')->where('del.qty >', 1)->deleteBatch($data, 'order, line');
2525

2626
// OR
2727
$builder
2828
->setData($data, true, 'del')
2929
->onConstraint('order, line')
30-
->where('order_line.qty >', 1)
30+
->where('del.qty >', 1)
3131
->deleteBatch();
3232

3333
/*
@@ -39,5 +39,5 @@
3939
* SELECT 48372 `order`, 5 `line`, 'Monitor' `product`, 2 `qty`
4040
* ) `del`
4141
* ON `order_line`.`order` = `del`.`order` AND `order_line`.`line` = `del`.`line`
42-
* WHERE `order_line`.`qty` > 1
42+
* WHERE `del`.`qty` > 1
4343
*/

0 commit comments

Comments
 (0)