Public Member Functions | |
| __construct ($base='', $args=array()) | |
| gen () | |
| Q ($base, $args=array()) | |
| SAnd ($sql) | |
| SOr ($sql) | |
| SDef ($sql, $k='AND') | |
| keywords ($string, $del=' ') | |
Public Attributes | |
| $ands = array() | |
Protected Attributes | |
| $db | |
| $where = '' | |
| Pluf_SQL::__construct | ( | $ | base = '', |
|
| $ | args = array() | |||
| ) |
Construct the constructor with a default condition.
| Pluf_SQL::gen | ( | ) |
Returns the where clause.
| Pluf_SQL::Q | ( | $ | base, | |
| $ | args = array() | |||
| ) |
Add a condition.
| string | String to 'interpolate' | |
| mixed | String or array of parameters (array()) |
| Pluf_SQL::SAnd | ( | $ | sql | ) |
| Pluf_SQL::SOr | ( | $ | sql | ) |
| Pluf_SQL::SDef | ( | $ | sql, | |
| $ | k = 'AND' | |||
| ) |
Add another SQL to the current
| Pluf_SQL | Other object to add to the current. | |
| string | Type of addition |
| Pluf_SQL::keywords | ( | $ | string, | |
| $ | del = ' ' | |||
| ) |
Get keywords.
Considering a query string, explode the query string in keywords given a defined delimiter.
| string | Query string | |
| string | delimiter (' ') |
Pluf_SQL::$db [protected] |
Pluf_SQL::$where = '' [protected] |
| Pluf_SQL::$ands = array() |