public function quote($value)
    {
        switch (true) {
            case $value === null:
                return 'null';

            case $value === true:
                return '1';

            case $value === false:
                return '0';

            case $value instanceof Expr:
                return $value->getValue();

            case is_int($value) || ctype_digit($value):
                return (int) $value;

            case is_float($value):
                // Convert to non-locale aware float to prevent possible commas
                return sprintf('%F', $value);

            case is_array($value):
                // Supports MVA attributes
                if (!count($value)) {
                    return '()';
                }

                return '('.implode(',', $this->quoteArr($value)).')';
        }

        return $this->conn->quote($value);
    }