mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-02-05 20:18:42 +00:00
Implementing raw query+execute
This commit is contained in:
parent
7307860d07
commit
bc217f5490
|
|
@ -891,4 +891,12 @@ class Builder extends BuilderAbstract
|
||||||
{
|
{
|
||||||
return clone($this);
|
return clone($this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function execute()
|
||||||
|
{
|
||||||
|
$sth = $this->connection->con->prepare($this->toSQL());
|
||||||
|
$sth->execute();
|
||||||
|
|
||||||
|
return $sth;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -124,7 +124,7 @@ class Grammar extends GrammarAbstract
|
||||||
$components = $this->selectComponents;
|
$components = $this->selectComponents;
|
||||||
break;
|
break;
|
||||||
case QueryType::RAW:
|
case QueryType::RAW:
|
||||||
return $query->raw;
|
return [$query->raw];
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new \InvalidArgumentException('Unknown query type.');
|
throw new \InvalidArgumentException('Unknown query type.');
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user