protected function buildMatchValue($value, &$params)
    {
        if (empty($value)) {
            return '""';
        }

        if ($value instanceof Expression) {
            $params = array_merge($params, $value->params);
            return $value->expression;
        }

        $parts = [];
        foreach ((array) $value as $v) {
            if ($v instanceof Expression) {
                $params = array_merge($params, $v->params);
                $parts[] = $v->expression;
            } else {
                $phName = self::PARAM_PREFIX . count($params);
                $parts[] = $phName;
                $params[$phName] = $v;
            }
        }

        return implode(' | ', $parts);
    }