public function toSQL(Parameters $params, bool $inner_clause)
    {
        if ($key = $this->getKey())
        {
            try
            {
                $params->get($key);
            }
            catch (\OutOfRangeException $e)
            {
                // Not a valid key, replace
                $key = null;
            }
        }

        if (!$key)
            $key = $params->assign(null);

        // Rebind, to be sure
        $this->bind($params, $key, array($params->getDriver(), 'formatArray'));
        return ':' . $key;
    }
public function toSQL(Parameters $params, bool $inner_clause)
    {
        if ($key = $this->getKey())
        {
            try
            {
                $params->get($key);
            }
            catch (\OutOfRangeException $e)
            {
                // Not a valid key, replace
                $key = null;
            }
        }

        if (!$key)
            $key = $params->assign(null);

        // Rebind, to be sure
        $this->bind($params, $key, array($params->getDriver(), 'formatArray'));
        return ':' . $key;
    }
public function toSQL ( Parameters $ params , bool $ inner_clause ) { if ( $ key = $ this -> getKey ( ) ) { try { $ params -> get ( $ key ) ; } catch ( \ OutOfRangeException $ e ) { // Not a valid key, replace $ key = null ; } } if ( ! $ key ) $ key = $ params -> assign ( null ) ; // Rebind, to be sure $ this -> bind ( $ params , $ key , array ( $ params -> getDriver ( ) , 'formatArray' ) ) ; return ':' . $ key ; }
Write a constant array clause as SQL query syntax
@param Parameters $params The query parameters: tables and placeholder values
@return string The generated SQL
Write a constant array clause as SQL query syntax