lintel 0.2.0
Loading...
Searching...
No Matches
Public Member Functions | Friends | List of all members
lintel::postgresql::Statement Class Reference

#include <Statement.h>

Public Member Functions

 Statement (const Connection &connection)
 
std::shared_ptr< Result > execute (const std::string &query)
 
std::shared_ptr< Result > execute (const std::string &query, const std::vector< std::string > &params)
 

Friends

class db::Statement
 
class db::Cursor
 

Detailed Description

Executes SQL statements on a PostgreSQL connection.

Constructor & Destructor Documentation

◆ Statement()

Constructs a Statement bound to the given connection.

Parameters
connectionthe PostgreSQL connection

Member Function Documentation

◆ execute() [1/2]

std::shared_ptr< Result > lintel::postgresql::Statement::execute ( const std::string &  query)

Executes a plain SQL query.

Parameters
querythe SQL query string
Returns
shared pointer to the result

◆ execute() [2/2]

std::shared_ptr< Result > lintel::postgresql::Statement::execute ( const std::string &  query,
const std::vector< std::string > &  params 
)

Executes a parameterized SQL query.

Parameters
querythe SQL query with placeholders
paramsthe parameter values as strings
Returns
shared pointer to the result

Friends And Related Symbol Documentation

◆ db::Cursor

◆ db::Statement


The documentation for this class was generated from the following file: