Update and rename execute.md to update.md

This commit is contained in:
Linden authored and GitHub committed 2021-09-19 07:03:42 +10:00
1 parent 39739edbfe
commit 1b8b6fd2de
1 file changed
+3 -3
+3 -3
View File
@@ -1,14 +1,14 @@
# Execute
# Update
Execute a query and returns the number of affected rows.
### Usage
```lua
exports.oxmysql:execute(query, {}, function(affectedRows)
exports.oxmysql:update(query, {}, function(affectedRows)
print('Updated '..affectedRows..' rows')
end)
print('I will be printed before query result')
```
```lua
local affectedRows = exports.oxmysql:executeSync(query, {})
local affectedRows = exports.oxmysql:updateSync(query, {})
print('Updated '..affectedRows..' rows')
```