Consider this simple class, that I will use for one of my Domain objects with EF Core 3.1:
using System;
namespace Blah.Domain
{
public class Response
{
public int Id { get; set; }
public string FullResponseText { get; set; }
public string HttpResponseCode { get; set; }
public string TransactionId { get; set; }
public string TransactionType { get; set; }
public DateTime CreatedDate { get; set; }
}
}
Having a database background, I do not want to use the default type of nvarchar(max) as the column type for string values in my database (SQL Server). How do I specify the column types to be used by EF when creating the table?
Also, do I have to include the whole SYSTEM Namespace just to be able to have the DateTime option available to me for my CreatedDate field or is there another way?