Example #1
0
    private static SqlType GetSqlType(DescribeResultSetContainer resultSetColumn)
    {
        var ambiguousType = GetAmbiguousSqlType(resultSetColumn);
        var sqlType       = AmbiguousSqlTypeToSqlTypeConverter.Convert(ambiguousType);

        return(sqlType);
    }
    public static SqlColumn InformationSchemaColumnToSqlColumn(SISColumn column)
    {
        var sqlColumn = new SqlColumn()
        {
            Name            = column.COLUMN_NAME,
            IsNullable      = column.IS_NULLABLE == "YES",
            OrdinalPosition = column.ORDINAL_POSITION,
            Default         = column.COLUMN_DEFAULT,
        };

        var ambigiousSqlType = FromInformationSchemaColumn(column);

        sqlColumn.SqlDataType = AmbiguousSqlTypeToSqlTypeConverter.Convert(ambigiousSqlType);
        return(sqlColumn);
    }