SQLite TOTAL_CHANGES() Function
Example
Insert two rows, and return the total number of changes:
INSERT INTO Shippers (ShipperName)
VALUES ('Fast Bikes'), ('Slow Boats');
SELECT TOTAL_CHANGES();
Try it Yourself »
Definition and Usage
The TOTAL_CHANGES() function returns the number of rows that were inserted, updated or deleted since the connection was opened.
Note: Our editor builds the Northwind database with many inserts when it opens, so the number can be large.
Tip: Also look at CHANGES().
Syntax
TOTAL_CHANGES()
Technical Details
| Return type: | Integer |
|---|