Skip to content

Instantly share code, notes, and snippets.

@runningdemo
Created January 13, 2016 13:54
Show Gist options
  • Save runningdemo/a064a7d2615df03c151e to your computer and use it in GitHub Desktop.
Save runningdemo/a064a7d2615df03c151e to your computer and use it in GitHub Desktop.
NSString *sql = [NSString stringWithFormat:@"insert INTO bookmark (href, title, tags, notes) values ('%@', '%@', '%@', '%@');",
bookmark.href,
bookmark.title,
[bookmark.tags componentsJoinedByString:@","],
bookmark.notes
];
[self.db executeUpdate:@"insert INTO bookmark (href, title, tags, notes) values (?, ?, ?, ?)", bookmark.href, bookmark.title, bookmark.tags, bookmark.notes];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment