Beispiel #1
0
 /// <summary>
 /// Specifies SQL Server CHAR(n) data type for column.
 /// </summary>
 /// <param name="column">The column.</param>
 /// <param name="size">The size of the data type.</param>
 /// <returns>This column for fluent coding.</returns>
 public static _String AsSqlChar(this _String column, int size)
 {
     column.VerifyNotNull(nameof(column));
     if (size < MIN_CHAR_SIZE || size > MAX_CHAR_SIZE)
     {
         throw new ArgumentOutOfRangeException(nameof(size));
     }
     column.SetSqlType(SqlType.Char(column, size));
     return(column);
 }
Beispiel #2
0
 /// <summary>
 /// Specifies SQL Server CHAR(MAX) data type for column.
 /// </summary>
 /// <param name="column">The column.</param>
 /// <returns>This column for fluent coding.</returns>
 public static _String AsSqlCharMax(this _String column)
 {
     column.VerifyNotNull(nameof(column));
     column.SetSqlType(SqlType.Char(column, -1));
     return(column);
 }