Rygel.Database.Database.query_value – librygel-db Reference Manual

# query_value

## Description:

public int query_value (string sql, Value[]? args = null) throws DatabaseError

Execute a SQL query that returns a single number.

## Parameters:

sql | The SQL query to run.
args | Values to bind in the SQL query or null.

## Returns:

The contents of the first row's column as an int.

## Exceptions:

DatabaseError | if the underlying SQLite operation fails.