MCPcopy Create free account
hub / github.com/SOCI/soci / load_one

Method load_one

src/backends/sqlite3/statement.cpp:218–241  ·  view source on GitHub ↗

This is used for non-bulk operations

Source from the content-addressed store, hash-verified

216
217// This is used for non-bulk operations
218statement_backend::exec_fetch_result
219sqlite3_statement_backend::load_one()
220{
221 if( !databaseReady_ )
222 return ef_no_data;
223
224 statement_backend::exec_fetch_result retVal = ef_success;
225 int const res = sqlite3_step(stmt_);
226
227 if (SQLITE_DONE == res)
228 {
229 databaseReady_ = false;
230 retVal = ef_no_data;
231 }
232 else if (SQLITE_ROW == res)
233 {
234 }
235 else
236 {
237 // There is no useful context we can add to the error message here.
238 throw sqlite3_soci_error(session_.conn_, {});
239 }
240 return retVal;
241}
242
243// Execute statements once for every row of useData
244statement_backend::exec_fetch_result

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected