cranlike (version 1.0.2)

with_db: Perform a DB query, without explicit locking

Description

This is for read operations. They can also be called from within a transaction. In this case the database handle will be reused.

Usage

with_db(db_file, expr)

Arguments

db_file

File of the DB.

expr

Expression to evaluate, it can refer to the connection handle as db.