Options for "single-use", ReadOnly transactions, where Spanner chooses the read timestamp, subject to user-provided bounds.
This allows reading without blocking.
Because selection of the timestamp requires knowledge of which rows will be read, a single-use transaction can only be used with one read. See Client::Read() and Client::ExecuteQuery(). SingleUseOptions cannot be used to construct an application-level Transaction.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-07-26 UTC."],[[["This webpage provides documentation for `SingleUseOptions` in the Google Cloud Spanner C++ client library, with version 2.32.0 being the current version displayed."],["The latest version available for reference is 2.37.0-rc, and there are several previous versions with links for reference going as far back as 2.11.0."],["`SingleUseOptions` are used for \"single-use\" read-only transactions where Spanner chooses the read timestamp within user-specified bounds, enabling non-blocking reads."],["Single-use transactions are limited to one read and can be used with `Client::Read()` and `Client::ExecuteQuery()`."],["`SingleUseOptions` class has constructors that accept `ReadOnlyOptions`, `Timestamp` or `std::chrono::nanoseconds` to manage the characteristics of the transaction."]]],[]]