A simple SQL query object for SELECT statements.
Usage of this class in Cough allows for sharing base SQL so that less SQL code is copied and pasted amongst classes.
For example, if there is a Product object which has complicated SELECT SQL that joins into other tables, pulls extra data in the SELECT clause, includes a GROUP BY, and has default WHERE criteria like "is_retired = 0", then by using this you don't have to copy all those common parts into the all the collection static methods. Instead, they can share the base SQL and just add what they need. For example, to pull a single product one might do:
Another example might be pulling all products that have the same manufacturer ID:
Located in /as_query/As_SelectQuery.class.php (line 37)
As_Query | --As_SelectQuery
Inherited from As_Query
As_Query::$db
Inherited From As_Query
As_Query::__construct()
As_Query::add()
As_Query::buildWhereSql()
As_Query::execute()
As_Query::getEqualityOperatorFromValue()
As_Query::getInsertQuery()
As_Query::getSelectQuery()
As_Query::getString()
As_Query::getUpdateQuery()
As_Query::remapCriteria()
As_Query::run()
As_Query::setDb()
As_Query::__toString()
Documentation generated on Sun, 19 Oct 2008 11:56:30 -0500 by phpDocumentor 1.4.0