Queries to the database are implemented in one transaction