예제 #1
0
 public string GetUpdateBtobSql(BtobEmp query)
 {
     StringBuilder sql = new StringBuilder();
     try
     {
         query.Replace4MySQL();
         sql.AppendFormat("update btob_emp set update_date='{0}' where id='{1}';", CommonFunction.GetPHPTime(),query.id);
         return sql.ToString();
     }
     catch (Exception ex)
     {
         throw new Exception("VipUserGroupDao->GetUpdateBtobSql->" + sql.ToString() + ex.Message, ex);
     }
 }
예제 #2
0
 public string GetInsertBtobSql(BtobEmp query)
 {
     StringBuilder sql = new StringBuilder();
     try
     {
         query.Replace4MySQL();
         sql.AppendFormat("insert into btob_emp (`emp_id`, `group_id`, `status`, `create_date`, `update_date`) values ('{0}','{1}','{2}','{3}','{4}');", query.emp_id, query.group_id, query.status, CommonFunction.GetPHPTime(), CommonFunction.GetPHPTime());
         return sql.ToString();
     }
     catch (Exception ex)
     {
         throw new Exception("VipUserGroupDao->GetInsertBtobSql->" + sql.ToString() + ex.Message, ex);
     }
 }