| @@ 34-46 (lines=13) @@ | ||
| 31 | $this->orderBy = new Snippets\OrderBy(); |
|
| 32 | } |
|
| 33 | ||
| 34 | public function toString() |
|
| 35 | { |
|
| 36 | $queryParts = array( |
|
| 37 | 'DELETE', |
|
| 38 | $this->buildFrom(), |
|
| 39 | $this->buildJoin(), |
|
| 40 | $this->buildWhere($this->escaper), |
|
| 41 | $this->buildOrderBy(), |
|
| 42 | $this->buildLimit(), |
|
| 43 | ); |
|
| 44 | ||
| 45 | return implode(' ', array_filter($queryParts)); |
|
| 46 | } |
|
| 47 | ||
| 48 | public function from($table, $alias = null) |
|
| 49 | { |
|
| @@ 37-49 (lines=13) @@ | ||
| 34 | } |
|
| 35 | } |
|
| 36 | ||
| 37 | public function toString() |
|
| 38 | { |
|
| 39 | $queryParts = array( |
|
| 40 | $this->buildUpdate(), |
|
| 41 | $this->buildJoin(), |
|
| 42 | $this->buildSets(), |
|
| 43 | $this->buildWhere($this->escaper), |
|
| 44 | $this->buildOrderBy(), |
|
| 45 | $this->buildLimit(), |
|
| 46 | ); |
|
| 47 | ||
| 48 | return implode(' ', array_filter($queryParts)); |
|
| 49 | } |
|
| 50 | ||
| 51 | public function update($table, $alias = null) |
|
| 52 | { |
|