Esempio n. 1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromSasgsdescription(ref DataRow row, Sasgsdescription entity)
 {
     row.SetField("recty", entity.recty);
     row.SetField("taxgroup", entity.taxgroup);
     row.SetField("statecd", entity.statecd);
     row.SetField("countycd", entity.countycd);
     row.SetField("citycd", entity.citycd);
     row.SetField("othercd", entity.othercd);
     row.SetField("descrip", entity.descrip);
     row.SetField("userfield", entity.userfield);
 }
Esempio n. 2
0
        public static Sasgsdescription BuildSasgsdescriptionFromRow(DataRow row)
        {
            Sasgsdescription entity = new Sasgsdescription();

            entity.recty     = row.IsNull("recty") ? 0 : row.Field <int>("recty");
            entity.taxgroup  = row.IsNull("taxgroup") ? 0 : row.Field <int>("taxgroup");
            entity.statecd   = row.IsNull("statecd") ? string.Empty : row.Field <string>("statecd");
            entity.countycd  = row.IsNull("countycd") ? string.Empty : row.Field <string>("countycd");
            entity.citycd    = row.IsNull("citycd") ? string.Empty : row.Field <string>("citycd");
            entity.othercd   = row.IsNull("othercd") ? string.Empty : row.Field <string>("othercd");
            entity.descrip   = row.IsNull("descrip") ? string.Empty : row.Field <string>("descrip");
            entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }