final public function having($key, $value = '', $type = 'AND ', $escape = TRUE)
    {
        if (!is_array($key)) {
            $key = array($key => $value);
        }

        foreach ($key as $k => $v) {
            $prefix = (count($this->arrayHaving) == 0) ? '' : $type;

            if ($escape === TRUE) {
                $k = $this->identifiers($k);
            }

            if (!$this->hasOperator($k)) {
                $k .= ' = ';
            }

            if ($v != '') {
                $v = ' ' . $this->escape($v);
            }

            $this->arrayHaving[] = $prefix . $k . $v;
            if ($this->arrayCaching === TRUE) {
                $this->arrayCacheHaving[] = $prefix . $k . $v;
                $this->arrayCacheExists[] = 'having';
            }
        }

        return $this;
    }