title: Why won't Serilog log to table using WriteTo.MSSqlServer sink?
body: <p>I am new to Serilog and I wrote a small test .NET Core app which tries to write a log to a local SQL Server database.  The code below successfully creates the table, but no matter what I do I can't get it to write a log record.  I didn't see any errors suggesting there are permission issues.  Anyone have an idea?</p>
  
  <pre><code>using Serilog;
  using Serilog.Sinks.MSSqlServer;
  
  namespace SerilogTest
  {
      class Program
      {
  
  
          private static ILogger InitSqlLogger()
          {
              var columnOptions = new ColumnOptions();
              columnOptions.Store.Remove(StandardColumn.MessageTemplate);
              columnOptions.Store.Remove(StandardColumn.Properties);
              columnOptions.Store.Remove(StandardColumn.Exception);
              columnOptions.Store.Remove(StandardColumn.Level);
              columnOptions.Store.Remove(StandardColumn.TimeStamp);
              return new LoggerConfiguration()
                  .WriteTo.MSSqlServer(@"Server=(local);Database=LogEvents; Integrated Security = SSPI;", "Logs", autoCreateSqlTable: true, columnOptions: columnOptions)
                  .CreateLogger();
          }
          private static void WriteLog()
          {
              var msg = "This is a {message:l}";
              Log.Logger.Information(msg, "test");
          }
          static void Main(string[] args)
          {
              Log.Logger = InitSqlLogger();
              WriteLog();
          }
      }
  }
  </code></pre>