Exemple #1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromPdsrlookupresults(ref DataRow row, Pdsrlookupresults entity)
 {
     row.SetField("startdt", entity.startdt);
     row.SetField("enddt", entity.enddt);
     row.SetField("refer", entity.refer);
     row.SetField("rowid-pdsr", entity.rowidPdsr.ToByteArray());
     row.SetField("userfield", entity.userfield);
 }
Exemple #2
0
        public static Pdsrlookupresults BuildPdsrlookupresultsFromRow(DataRow row)
        {
            Pdsrlookupresults entity = new Pdsrlookupresults();

            entity.startdt   = row.Field <DateTime?>("startdt");
            entity.enddt     = row.Field <DateTime?>("enddt");
            entity.refer     = row.IsNull("refer") ? string.Empty : row.Field <string>("refer");
            entity.rowidPdsr = row.Field <byte[]>("rowid-pdsr").ToStringEncoded();
            entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }