i need to copy this database file and save it in someother location or i can take backup of the db file. is there a way to do this programmatically.
Thanks Satish
i need to copy this database file and save it in someother location or i can take backup of the db file. is there a way to do this programmatically.
Thanks Satish
Unless you've jailbroken your iPhone, there's no way of accessing the sqlite3 database directly on the phone.
If you're talking about getting access to the database from your computer, you can do it by grabbing the database files out of the iPhone backup files. To do that, you'll need to grab a copy of Erica Sadun's mdhelper (binary file) command line utility, and run it from the PC you sync your laptop with like so:
mdhelper -files "AddressBook.sqlitedb" -extract -glob
This will create a "~/Desktop/Recovered iPhone Files
" directory containing a file called AddressBook.sqlitedb
, which you can access directly or query using your programming language of choice.
If you don't trust downloading and running binary files without knowing what they do, you can look at the source on Github and compile it yourself.
Thanks for the quick reply, all i need to do is backup the addressbook.sqlite.db file from iphone (non jailbroken) to a server(which can be anything say cloud or a web server) and restore it back to the same location on iphone. and one more question Nathan is there a way to get the location, name , and extension of an image resided on iphone.
Thanks Satish