Skip to content

Commit 31e6998

Browse files
committed
Remove use of setAlias()
1 parent 8cf5dd6 commit 31e6998

File tree

2 files changed

+2
-7
lines changed

2 files changed

+2
-7
lines changed

tests/system/Database/Live/DeleteTest.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,7 @@ public function testDeleteBatch()
8181
];
8282

8383
$this->db->table('user')
84-
->setAlias('data')
85-
->setData($data)
84+
->setData($data, null, 'data')
8685
->onConstraint(['id' => 'userid', 'name' => 'username'])
8786
->deleteBatch();
8887

user_guide_src/source/database/query_builder/118.php

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,7 @@
2121
],
2222
];
2323

24-
$builder->setAlias('del')->where('del.qty >', 1)->deleteBatch($data, 'order, line');
25-
26-
// OR
27-
$builder
28-
->setData($data, true, 'del')
24+
$builder->setData($data, true, 'del')
2925
->onConstraint('order, line')
3026
->where('del.qty >', 1)
3127
->deleteBatch();

0 commit comments

Comments
 (0)