VSQLite++  0.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends
Public Member Functions | Private Attributes | List of all members
sqlite::view Struct Reference

view is used to create views. In SQLite a view can only be queried. INSERT, DELETE and UPDATE will fail on a view More...

#include <view.hpp>

Collaboration diagram for sqlite::view:
Collaboration graph

Public Member Functions

 view (connection &con)
 constructor
 
 ~view ()
 destructor
 
void create (bool temporary, std::string const &alias, std::string const &sql_query)
 creates a view
 
void create (bool temporary, std::string const &database, std::string const &alias, std::string const &sql_query)
 creates a view
 
void drop (std::string const &alias)
 drops a view
 
void drop (std::string const &database, std::string const &alias)
 drops a view
 

Private Attributes

connectionm_con
 

Detailed Description

view is used to create views. In SQLite a view can only be queried. INSERT, DELETE and UPDATE will fail on a view

Definition at line 39 of file view.hpp.

Constructor & Destructor Documentation

sqlite::view::view ( connection con)

constructor

Parameters
cona reference to the connection object which should be used
sqlite::view::~view ( )

destructor

Member Function Documentation

void sqlite::view::create ( bool  temporary,
std::string const &  alias,
std::string const &  sql_query 
)

creates a view

Parameters
temporaryif this parameter is true the view will be present until drop will be called or the database was closed
aliasthe name of this view which should be used
sql_querythe SQL statement which represents the view
void sqlite::view::create ( bool  temporary,
std::string const &  database,
std::string const &  alias,
std::string const &  sql_query 
)

creates a view

Parameters
temporaryif this parameter is true the view will be present until drop will be called or the database was closed
databasename of the database where the view should be created in
aliasthe name of this view which should be used
sql_querythe SQL statement which represents the view
void sqlite::view::drop ( std::string const &  alias)

drops a view

Parameters
aliasname of the view which should be dropped
void sqlite::view::drop ( std::string const &  database,
std::string const &  alias 
)

drops a view

Parameters
databasename of the database where the view was created in
aliasname of the view which should be dropped

Member Data Documentation

connection& sqlite::view::m_con
private

Definition at line 86 of file view.hpp.


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