class Doctrine_View (View source)

Doctrine_View

this class represents a database view

Constants

DROP

SQL DROP constant

CREATE

SQL CREATE constant

SELECT

SQL SELECT constant

Properties

protected string $_name
protected Doctrine_Query $_query
protected Doctrine_Connection $_conn
protected string $_dql
protected string $_sql

Methods

__construct(Doctrine_Query $query, $viewName)

constructor

getQuery()

returns the associated query object

string
getName()

returns the name of this view

getConnection()

returns the connection object

void
create()

creates this view

void
drop()

drops this view from the database

execute()

returns a collection of Doctrine_Record objects

string
getSelectSql()

returns the select sql for this view

string
getViewSql()

Get the view sql string

string
getViewDql()

Get the view dql string

Details

__construct(Doctrine_Query $query, $viewName)

constructor

Parameters

Doctrine_Query $query
$viewName

Doctrine_Query getQuery()

returns the associated query object

Return Value

Doctrine_Query

string getName()

returns the name of this view

Return Value

string

Doctrine_Connection getConnection()

returns the connection object

Return Value

Doctrine_Connection

void create()

creates this view

Return Value

void

Exceptions

Doctrine_View_Exception

void drop()

drops this view from the database

Return Value

void

Exceptions

Doctrine_View_Exception

Doctrine_Collection execute()

returns a collection of Doctrine_Record objects

Return Value

Doctrine_Collection

string getSelectSql()

returns the select sql for this view

Return Value

string

string getViewSql()

Get the view sql string

Return Value

string $sql

string getViewDql()

Get the view dql string

Return Value

string $dql