Example #1
0
 public static List<int?> GetStationList(string connectionString)
 {
     using (MessageLogContext ctx = new MessageLogContext(connectionString))
     {
         return ctx.MessageLogs.Select(m => m.StationNo.HasValue ? m.StationNo : 0).Distinct().ToList();
     }
 }
Example #2
0
 public static List<string> GetProgramList(string connectionString)
 {
     using (MessageLogContext ctx = new MessageLogContext(connectionString))
     {
         return ctx.MessageLogs.Select(m => m.ProgramName).Distinct().ToList();
     }
 }