7.Delete one or more records

Delete one or more records

  • delete by id
err := engine.Id(1).Delete(&User{})
  • delete by other conditions
err := engine.Delete(&User{Name:"xlw"})