#include <freeQuery.h>
Public Member Functions | |
FreeQuery (std::string queryStr, const std::string &prefix="", bool useViewColumns=true) | |
virtual std::string | getSql (Driver &drv, const Type &type) const |
Returns SQL SELECT statement representing the current query. |
This class allows developers to specify everything after the FROM keyword. There are absolutely no restrictions on joins, subselects or other SQL language constructs.
iopc::FreeQuery::FreeQuery | ( | std::string | queryStr, | |
const std::string & | prefix = "" , |
|||
bool | useViewColumns = true | |||
) | [inline] |
queryStr | A query string that will be rendered after the FROM keyword in the resulting SELECT statement. The string is substituted according to rules described in Query::substituteQuery() | |
prefix | A prefix that will be rendered before each column name in the SELECT column list. Example: If a query prefix is "x", the generated statement will be SELECT x.col1, x.col2 FROM... | |
useViewColumns | Determines whether to render [db.viewColumn] or [db.column] for column names |
Returns SQL SELECT statement representing the current query.
drv | Database driver used to generate the statement | |
type | Type for which to generate the statement. Determines the columns/attributes that the SELECT returns. |
Implements iopc::Query.