mirror of
https://github.com/dg/dibi.git
synced 2025-08-04 13:17:58 +02:00
- REWRITTEN DibiTranslar
- allows modifiers inside SQL -> modifiers become placeholders - new modifier %ex - expand array - new modifiers %or and %and - changed interface IDibiVariable and implementation DibiVariable
This commit is contained in:
@@ -69,7 +69,7 @@ class DibiDataSource extends NObject implements IDataSource
|
||||
{
|
||||
return $this->connection->query('
|
||||
SELECT %n', ($cols === NULL ? '*' : $cols), '
|
||||
FROM %sql', $this->sql, '
|
||||
FROM', $this->sql, '
|
||||
%ofs %lmt', $offset, $limit
|
||||
);
|
||||
}
|
||||
@@ -83,8 +83,7 @@ class DibiDataSource extends NObject implements IDataSource
|
||||
{
|
||||
if ($this->count === NULL) {
|
||||
$this->count = $this->connection->query('
|
||||
SELECT COUNT(*)
|
||||
FROM %sql', $this->sql
|
||||
SELECT COUNT(*) FROM', $this->sql
|
||||
)->fetchSingle();
|
||||
}
|
||||
return $this->count;
|
||||
|
Reference in New Issue
Block a user