/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromGlbdgaccountlookupresults(ref DataRow row, Glbdgaccountlookupresults entity) { row.SetField("glno", entity.glno); row.SetField("notesfl", entity.notesfl); row.SetField("lookupnm", entity.lookupnm); row.SetField("gltitle", entity.gltitle); row.SetField("revno", entity.revno); row.SetField("rowid-glsb", entity.rowidGlsb.ToByteArray()); row.SetField("userfield", entity.userfield); }
public static Glbdgaccountlookupresults BuildGlbdgaccountlookupresultsFromRow(DataRow row) { Glbdgaccountlookupresults entity = new Glbdgaccountlookupresults(); entity.glno = row.IsNull("glno") ? string.Empty : row.Field <string>("glno"); entity.notesfl = row.IsNull("notesfl") ? string.Empty : row.Field <string>("notesfl"); entity.lookupnm = row.IsNull("lookupnm") ? string.Empty : row.Field <string>("lookupnm"); entity.gltitle = row.IsNull("gltitle") ? string.Empty : row.Field <string>("gltitle"); entity.revno = row.IsNull("revno") ? 0 : row.Field <int>("revno"); entity.rowidGlsb = row.Field <byte[]>("rowid-glsb").ToStringEncoded(); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }