def get_column_declaration_sql(self, name, field):
        if 'column_definition' in field:
            column_def = self.get_custom_type_declaration_sql(field)
        else:
            default = self.get_default_value_declaration_sql(field)

            charset = field.get('charset', '')
            if charset:
                charset = ' ' + self.get_column_charset_declaration_sql(charset)

            collation = field.get('collation', '')
            if charset:
                charset = ' ' + self.get_column_collation_declaration_sql(charset)

            notnull = field.get('notnull', '')
            if notnull:
                notnull = ' NOT NULL'
            else:
                notnull = ''

            unique = field.get('unique', '')
            if unique:
                unique = ' ' + self.get_unique_field_declaration_sql()
            else:
                unique = ''

            check = field.get('check', '')

            type_decl = self.get_sql_type_declaration(field)
            column_def = type_decl + charset + default + notnull + unique + check + collation

        return name + ' ' + column_def
dataset/ETHPy150Open sdispater/orator/orator/dbal/platforms/platform.py/Platform.get_column_declaration_sql/original