I have a legacy database that uses the smalldatetime
SQL data type. That maps fine to the standard DateTime
. However, when I use SchemaExport, it understandably generates the column with datetime
format. What custom type should I be using in my mapping so that the generated column is smalldatetime
?
// Does not work as custom type not known
Map(x => x.BirthDate).Column("dtBirthDate").Not.Nullable().CustomType("smalldatetime");