Closed beppler closed 5 years ago
On DbTypes x SqlServer is documented that the types generated for DbType.Binary is the following:
Based on , if the size of binary is not specifed the declaration is same as binary(1)
Also, based on SQL Server Data Type Mappings the type used for DbType.Binary could be binary, varbinary or image.
SQL Server image datatype is deprecated, but should be used for SQL Server 2005 or older.
We can not know only based on enumeration if user want to use binary or varbinary so a decision must be made between one of the following options:
Use binary:
Use varbinary:
I've created a project fork at https://github.com/mpsinfo/sharpdata that contains this update using the varbinary option.
Resolved by #19.
On DbTypes x SqlServer is documented that the types generated for DbType.Binary is the following:
Based on , if the size of binary is not specifed the declaration is same as binary(1)
Also, based on SQL Server Data Type Mappings the type used for DbType.Binary could be binary, varbinary or image.
SQL Server image datatype is deprecated, but should be used for SQL Server 2005 or older.
We can not know only based on enumeration if user want to use binary or varbinary so a decision must be made between one of the following options:
Use binary:
Use varbinary: