SQL CaseWhen/Sum + ContactRequest API fix

This commit is contained in:
2021-04-10 01:33:40 +02:00
parent 7506a81514
commit 896bbe76b4
8 changed files with 121 additions and 38 deletions

View File

@@ -0,0 +1,23 @@
<?php
namespace Driver\SQL\Expression;
use Driver\SQL\Condition\Condition;
class CaseWhen extends Expression {
private Condition $condition;
private $trueCase;
private $falseCase;
public function __construct(Condition $condition, $trueCase, $falseCase) {
$this->condition = $condition;
$this->trueCase = $trueCase;
$this->falseCase = $falseCase;
}
public function getCondition(): Condition { return $this->condition; }
public function getTrueCase() { return $this->trueCase; }
public function getFalseCase() { return $this->falseCase; }
}