Skip to content

Instantly share code, notes, and snippets.

@identity2
Created June 8, 2019 05:16
Show Gist options
  • Save identity2/943026c6f2822288d047321bee411a8c to your computer and use it in GitHub Desktop.
Save identity2/943026c6f2822288d047321bee411a8c to your computer and use it in GitHub Desktop.
update contact
func updateContact(_ contact: Contact) {
let queryString = "UPDATE Contact SET Name = \(Contact.name), Phone = \(Contact.phoneNumber), City = \(Contact.city) WHERE ID = \(Contact.id)"
mainDB!.executeUpdate(queryString, withArgumentsIn: nil)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment