Created
September 21, 2011 13:42
-
-
Save ghiboz/1232051 to your computer and use it in GitHub Desktop.
store nsdate into db
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// salvo su db | |
sqlite3_bind_double(updateStatement, 5, [[person birthdate] timeIntervalSince1970]); | |
// leggo da db | |
person.birthdate = [NSDate dateWithTimeIntervalSince1970:sqlite3_column_double(selectStatement, 5)]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment