Doctrine\DBAL\Platforms\OraclePlatform::getColumnDeclarationSQL PHP Method

getColumnDeclarationSQL() public method

public getColumnDeclarationSQL ( $name, array $field )
$field array
    public function getColumnDeclarationSQL($name, array $field)
    {
        if (isset($field['columnDefinition'])) {
            $columnDef = $this->getCustomTypeDeclarationSQL($field);
        } else {
            $default = $this->getDefaultValueDeclarationSQL($field);
            $notnull = '';
            if (isset($field['notnull'])) {
                $notnull = $field['notnull'] ? ' NOT NULL' : ' NULL';
            }
            $unique = isset($field['unique']) && $field['unique'] ? ' ' . $this->getUniqueFieldDeclarationSQL() : '';
            $check = isset($field['check']) && $field['check'] ? ' ' . $field['check'] : '';
            $typeDecl = $field['type']->getSQLDeclaration($field, $this);
            $columnDef = $typeDecl . $default . $notnull . $unique . $check;
        }
        return $name . ' ' . $columnDef;
    }
OraclePlatform