for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Helix\DB\Fluent\Value;
use Helix\DB\Fluent\AbstractTrait;
use Helix\DB\Fluent\Value;
/**
* Produces type-independent expressions for the instance.
*/
trait ValueTrait {
use AbstractTrait;
use AggregateTrait;
use ComparisonTrait;
* `COALESCE($this, ...$values)`
*
* @param scalar[] $values
* @return Value
public function coalesce (array $values) {
array_unshift($values, $this);
$values = $this->db->quoteList($values);
return Value::factory($this->db, "COALESCE({$values})");
}