BuildOnConflictTrait.php from auraphp/Aura.SqlQuery
// Source: https://github.com/auraphp/Aura.SqlQuery | License: MIT | Copyright 2011-2026, Aura for PHP
// Provided via justclaw.it.com; keep this notice with the code.
<?php
/**
*
* This file is part of Aura for PHP.
*
* @license http://opensource.org/licenses/mit-license.php MIT
*
*/
namespace Aura\SqlQuery\Common;
use Aura\SqlQuery\Exception\LogicException;
/**
*
* A trait to build ON CONFLICT clauses for Postgres and SQLite.
*
* @package Aura.SqlQuery
*
*/
trait BuildOnConflictTrait
{
/**
*
* Builds the `ON CONFLICT` clause of the statement.
*
* @param string|null $target The conflict target.
* @param array<string, string> $update_values The columns and values
* to update.
* @param list<string> $where Optional WHERE conditions.
*
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key